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

Post-#924 refactor #944

Closed
Rich-Harris opened this issue Nov 23, 2017 · 1 comment
Closed

Post-#924 refactor #944

Rich-Harris opened this issue Nov 23, 2017 · 1 comment

Comments

@Rich-Harris
Copy link
Member

#924 changed things round a bit, such that more analysis takes place in one go, at the start of the compilation process, rather than piecemeal later on through generator.contextualise. This means more stuff is shared between the DOM and SSR compilers, for example.

Now that that's done, it might be good to get rid of generator.contextualise altogether — it's a bit of a strange beast, doing analysis and code transformation at the same time in a way that's a little inscrutable. My hunch is that things would become a bit simpler as a result.

My hunch could be wrong through — there are basically three phases (walkTemplate, which is compiler-agnostic, preprocess, which is compiler-specific and sets things up for the final phase, and lastly the actual code generation). It might well turn out that we can't put more stuff into walkTemplate because it depends on work that necessarily happens later.

Regardless, I'll leave this issue here to remind myself to look into it if I feel sufficiently motivated.

@Rich-Harris
Copy link
Member Author

this was basically #1316

sacrosanctic pushed a commit to sacrosanctic/svelte that referenced this issue Dec 24, 2024
sync svelte docs

Co-authored-by: Rich-Harris <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants