-
Notifications
You must be signed in to change notification settings - Fork 127
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
Incompatibility between Solid's markers and nginx Server Side Includes (SSI) #262
Comments
I made some digging and it appears that quite a few web servers are using these kind of markers: |
I mean they are HTML comments. Which I'm gathering we all need to use. Is specifically the |
Yes, for example for nginx here's the syntax:
So yeah the # is part of the syntax for them, and after their transformation, this comment has disappeared altogether. Then hydration fails. |
Ok good to know. We can look at changing this but it applies to both the compiler and the runtime output which means I need to do this as a minor change minimum so that we can line them up. |
The sequence beginning lighttpd mod_ssi (when enabled) will detect |
Hello, I'm currently encountering an issue when using Solid's server-side rendering (SSR) markers (
<!--#-->
) in an environment where nginx's Server Side Includes (SSI) is enabled. Essentially, nginx is trying to include files when it encounters these markers in the source code it is serving, which is disrupting the entire hydration process.I get each Solid marker replaced with the error message:
"[an error occurred while processing the directive]"
. Example:I've identified that the cause of the problem is the overlap between Solid's SSR markers and the marker definition (
<!--#
) used by nginx for SSI. This marker definition appears to be hard-coded into nginx's source code.Given that it's unlikely for nginx to adjust this behavior for us, I was wondering whether there's a possible workaround or adjustment we can make on the dom-expression side of things. Specifically, I'm referring to this section of the code:
dom-expressions/packages/babel-plugin-jsx-dom-expressions/src/ssr/element.js
Line 471 in a85d688
Do you think it would be feasible to make changes to the markers used by Solid, or perhaps introduce some level of customization so users can adjust these markers to avoid conflicts with other technologies like nginx SSI?
I appreciate any assistance or insights you might be able to provide.
Let me know if you need anything else, or if there's anything you want to adjust in the issue.
Cheers,
Jérémy
The text was updated successfully, but these errors were encountered: