Are there any plans on porting this module to Drupal 8?

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

lakesta created an issue. See original summary.

whiz11’s picture

Have anybody started a port on Drupal 8?

whiz11’s picture

demonde’s picture

Is there any alternative approach in Drupal 8 for this module?

sandeepguntaka’s picture

Here is an initial code that i've written for D8 https://github.com/sandeepguntaka/token_formatters

adamps’s picture

@Dave Reid please can you advise how we go forward? Are you willing for there to be a D8 version or should we create a separate module? Do you want to maintain D8 too, or would you prefer that someone else does it?

I also have a version - sorry I wrote the code before finding the comment from @sandeepguntaka. Good news is that the two versions are similar. My version has some potential advantages:

  • Include the ability to link
  • Closer to the original, in particular for the naming of the settings, which should be easier for migration
  • Use dependency injection

However there are still some gaps:

  • Support the entity:* tokens
  • Access checking - hopefully D8 can handle this automatically or at least more easily, but I haven't checked this out yet
pasqualle’s picture

Title: Port to Drupal 8? » Port Token formatters to Drupal 8
voleger’s picture

Can be 2.0.x branch introduced for the development? The porting process has to start at some point, so this might help contributors propose changes by creating the issue forks based on the development branch.

geek-merlin’s picture

pasqualle’s picture

or ping Dave Reid on slack for co-maintainer access..

voleger’s picture

Thanks @geek-merlin and @Pasqualle for suggestion.

I had asked for the co-maintainer role (via PM @Dave Reid in Drupal Slack).

carsoncho made their first commit to this issue’s fork.

carsoncho’s picture

Has there been any movement on this? I went ahead and created an issue fork to hopefully move this along. I took @sandeepguntaka's version of the module and made it the initial starting point for the 8.x branch.

I also added entity_reference_revisions as an available field type to be used.

azinck made their first commit to this issue’s fork.

adamps’s picture

Please see #6, which has a version with some improvements.

Comment #14 states that the starting point was @sandeepguntaka's version from #5 which may be missing these improvements.

azinck’s picture

@AdamPS: is your version of the module available somewhere? I don't see it linked anywhere.

adamps’s picture

I'm sorry you are right I never put a link. It is here: https://github.com/AdamPS/token_formatters.

adamps’s picture

I think that my code is a direct port - same formatter settings, same form UI text, everything the same as much as I was able to. As it says in #6 there are still some gaps:

  • Support the entity:* tokens
  • Access checking - hopefully D8 can handle this automatically or at least more easily, but I haven't checked this out yet

I think @sandeepguntaka version changes lots of details that would make migration from D7 harder and it has more gaps (again see #6). However on the plus side it adds a test which would be good to keep.

adamps’s picture

I triggered the official process to take over an abandoned module: #3243341: Offering to maintain Token Formatters. If I succeed I can add others as maintainers - please let me know if you are interested.

Until then, anyone is welcome to contribute to the github version.

adamps’s picture

They would not assign me as maintainer because apparently I don't have the "vetted" role. Maybe someone else would like to try?

minnur’s picture

Drupal 9 and 10 version support https://github.com/minnur/token_formatters

voleger’s picture

adamps’s picture

Title: Port Token formatters to Drupal 8 » Port Token formatters to Drupal 9/10

@AdamPS I created a request

Great thanks.

There are at least 3 versions:

  • MR: Similar to D7, but changes some names/text and has some gaps.
  • #18/19 by @AdamPS: I made a direct port from D7 also some gaps but less than MR. Not yet tested on D10.
  • #22 by @minnur: True it still provides formatters that use tokens, however it's quite far from the D7 version.

This issue title is "Port Token formatters to Drupal 9/10". I feel we should try to do that - create as closely as possible an equivalent module that would make easy upgrade for the 700 remaining sites on the D7 version.

voleger’s picture

Version: 7.x-1.2 » 1.0.x-dev
Status: Active » Needs work

Ok, let's keep it up.
I'd created 1.0.x branch for Drupal 9.5/10.0 port.

Please create an MR for the initial commit. Based on already existing ports, we need an installable version in the dev branch ASAP. We can address the rest of the adjustments that need to be done in follow-up issues. #3335165: [META] Prepare 1.0.0 release

adamps’s picture

Great nice work. Once there is a working release then I will create some new issues for improvements.

voleger’s picture

Status: Needs work » Reviewed & tested by the community

Ok, I'm going to merge 8.x-1x of the issue fork into 1.0.x branch.

  • voleger committed ffec57c6 on 1.0.x authored by carsoncho
    Issue #2819831 by carsoncho, voleger, azinck, AdamPS, whiz11, Pasqualle...
voleger’s picture

Merged! Thanks, see you at #3335165: [META] Prepare 1.0.0 release

voleger’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.