Tell templates where they're being rendered #26
Labels
A-templates
Area: templates
C-enhancement
Category: enhancement
D-easy
Difficulty: easy
good first issue
Good for newcomers
P-high
Priority: high
S-in-development
Status: in development
Milestone
Is your feature request related to a problem? Please describe.
Right now,
web_sys
panics if you call it on the server, and detecting if you're on the server with it is difficult and badly documented. Thus, it's very difficult to have client-side-only logic in Perseus, which is really a must for any framework like this.Describe the solution you'd like
Perseus should provide a simple boolean argument to templates along with their state telling them if they're being rendered on the client or the server. This will make things orders of magnitude easier!
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Add any other context or screenshots about the feature request here.
The text was updated successfully, but these errors were encountered: