Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fallback patterns and enabling/disabling custom patterns #107

Open
Alexnortung opened this issue Jan 25, 2024 · 5 comments
Open

Fallback patterns and enabling/disabling custom patterns #107

Alexnortung opened this issue Jan 25, 2024 · 5 comments
Assignees
Labels
enhancement New feature or request

Comments

@Alexnortung
Copy link
Collaborator

Feature request

Summary

Currently you have to create a pattern in the database to use a pattern. This means that you have to set up the patterns locally and in production unless you use other tools such as config sync. I think it would give a better developer experience to have a fallback pattern field which can be configured directly on the pluginOptions preferably next to the enable option in the interface.

I also think it should be possible to disable the custom patterns, such that the fallback pattern is the only one being used and cannot be changed by users who don't know what they are doing.

Related issue(s)/PR(s)

This might resolve the problem in #54

@Alexnortung Alexnortung added the enhancement New feature or request label Jan 25, 2024
@boazpoolman
Copy link
Member

I agree having a fallback pattern could be nice.
Also to indeed prevent #54.

Though I wouldn't want to replace the pattern creation in the admin panel completely.
Adding the patterns through the admin panel allows for better validation and all-in-all better user experience.
So a user would still rely on tools such as config sync to handle their config migration.
Just like you would for permissions, roles and other settings.

@Alexnortung
Copy link
Collaborator Author

Great, I think we are on the same page :)

@boazpoolman
Copy link
Member

This issue was fixed with this PR and released with version 1.0.0-beta.6.

@Alexnortung
Copy link
Collaborator Author

@boazpoolman nice addition, however I was thinking of a way to do this individually on each content type. Like when you enable url alias for a content type such as "page" you would also get a pattern input field to create a fallback pattern. This pattern could just be saved in the pluginOptions of the content type.
I hope it is okay that I reopen this issue, let me know if it should be a new issue instead :)

@Alexnortung Alexnortung reopened this Feb 4, 2024
@boazpoolman
Copy link
Member

Yeah. That sounds like a good next step.

Re-opening the issue is fine! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants