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

Provide Shortcode param Interface at Page Level #6579

Open
HenrySkup opened this issue Dec 4, 2019 · 3 comments
Open

Provide Shortcode param Interface at Page Level #6579

HenrySkup opened this issue Dec 4, 2019 · 3 comments
Labels
Milestone

Comments

@HenrySkup
Copy link

So, we have .HasShortcode to tell us, at a page level, if a shortcode is used. It would be useful to be able to access the shortcodes' params at this point, too, to allow for some finer grain control .

@bep
Copy link
Member

bep commented Dec 4, 2019

I don't see how. Params are per shortcode used, and you can use the same shortcode multiple times per content file.

@HenrySkup
Copy link
Author

true, but if the content has been parsed to find the shortcodes, i would assume that it could have access at that point to each shortcode's param values? My use case is:

I wand to have multiple canvases one one page (using a {{< canvas >}} shortcode that references the JS script that codes the canvas). All canvases react and style the same way, but each may use different dependencies.

Currently there is no way to indicate at a page level these different dependencies. Of course I could have differently named shortcodes to indicate this -- this wouldn't be very DRY.

@HenrySkup HenrySkup reopened this Dec 12, 2019
@bep
Copy link
Member

bep commented Dec 12, 2019

true, but if the content has been parsed to find the shortcodes, i would assume that it could have access at that point to each shortcode's param values?

That's true, I guess. But I need to think some about this.

@bep bep added this to the v0.63 milestone Dec 12, 2019
@bep bep modified the milestones: v0.63, v0.64 Jan 22, 2020
@bep bep modified the milestones: v0.64, v0.65 Jan 30, 2020
@bep bep modified the milestones: v0.65, v0.66 Feb 18, 2020
@bep bep modified the milestones: v0.66, v0.67 Mar 2, 2020
@bep bep modified the milestones: v0.67, v0.68 Mar 9, 2020
@bep bep modified the milestones: v0.68, v0.69 Mar 20, 2020
@bep bep modified the milestones: v0.69, v0.70 Apr 8, 2020
@bep bep modified the milestones: v0.70, v0.71 Apr 28, 2020
@bep bep modified the milestones: v0.71, v0.72 May 18, 2020
@bep bep modified the milestones: v0.72, v0.73 May 31, 2020
@bep bep modified the milestones: v0.73, v0.74 Jun 23, 2020
@bep bep removed this from the v0.74 milestone Jul 13, 2020
@bep bep modified the milestones: v0.116.0, v0.117.0 Aug 1, 2023
@bep bep modified the milestones: v0.117.0, v0.118.0 Aug 30, 2023
@bep bep modified the milestones: v0.118.0, v0.119.0 Sep 15, 2023
@bep bep modified the milestones: v0.119.0, v0.120.0 Oct 4, 2023
@bep bep modified the milestones: v0.120.0, v0.121.0 Oct 31, 2023
@bep bep modified the milestones: v0.121.0, v0.122.0 Dec 6, 2023
@bep bep modified the milestones: v0.122.0, v0.123.0, v0.124.0 Jan 27, 2024
@bep bep modified the milestones: v0.124.0, v0.125.0 Mar 4, 2024
@bep bep modified the milestones: v0.125.0, v0.126.0 Apr 23, 2024
@bep bep modified the milestones: v0.126.0, v0.127.0 May 15, 2024
@bep bep modified the milestones: v0.127.0, v0.128.0 Jun 8, 2024
@bep bep modified the milestones: v0.128.0, v0.129.0 Jun 21, 2024
@bep bep modified the milestones: v0.129.0, v0.131.0 Jul 22, 2024
@bep bep modified the milestones: v0.131.0, v0.133.0 Aug 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants