You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've read through the documentation but haven't managed to find anything useful. What I wish to accomplish is to add additional logic to the compiler before the components are compiled.
The use case I'm trying to achieve is to allow declarative specification of grid position from outside the component. The compiler should parse these instructions and when adjust the specific components styles based on "props" which are not dynamic. The specific idea is to allow easy use of grid row / column without having to create multiple components for each possible combination.
I've checked through the compilers API, but ... well, I couldn't deduct anything which may aid my use case. AST returns just source string I don't really understand.
Can someone point me to how I may start approaching this issue. Is it even possible given current compiler's API?
The text was updated successfully, but these errors were encountered:
The compiler is not currently pluginable and custom directives are not supported.
I'm not 100% sure on what you are trying to do so I can't comment on it's feasibility but there is currently no API to change compiler behaviour. Anything that cannot be done in a preprocessor, or using svelte's current component API is probably not going to work.
I've read through the documentation but haven't managed to find anything useful. What I wish to accomplish is to add additional logic to the compiler before the components are compiled.
The use case I'm trying to achieve is to allow declarative specification of grid position from outside the component. The compiler should parse these instructions and when adjust the specific components styles based on "props" which are not dynamic. The specific idea is to allow easy use of grid row / column without having to create multiple components for each possible combination.
I've checked through the compilers API, but ... well, I couldn't deduct anything which may aid my use case. AST returns just source string I don't really understand.
Can someone point me to how I may start approaching this issue. Is it even possible given current compiler's API?
The text was updated successfully, but these errors were encountered: