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

Technique of storing widgets configuration per instance? #60

Open
Yahav opened this issue Nov 9, 2019 · 2 comments
Open

Technique of storing widgets configuration per instance? #60

Yahav opened this issue Nov 9, 2019 · 2 comments

Comments

@Yahav
Copy link

Yahav commented Nov 9, 2019

My objective is to have my users be able to add widgets to their pages.
However some widgets may require user provided configuration, for example, a weather widget, the user will be required to input the desired city..
How/where would you store this instance specific information?
is that an existing functionality?

@imanghafoori1
Copy link
Owner

hmmm,... You mean something like October CMS widgets ?

@imanghafoori1
Copy link
Owner

I think you should pass your config data as the second argument to the @widget() and the will be passed to the controller of that widget.
that's it. in fact you should wrap some code around the current widgets according to your needs.

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

No branches or pull requests

2 participants