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

Serving CSS file through Head does not work. #23

Open
Methrat0n opened this issue Jan 9, 2022 · 1 comment
Open

Serving CSS file through Head does not work. #23

Methrat0n opened this issue Jan 9, 2022 · 1 comment

Comments

@Methrat0n
Copy link

Hello, I'm building a toy project with caldera to make sure it could be useful in a future project.
First of all, I have to say that all JS / TS related features work great out of the box and the api design is very simple, which is good for something so powerful.
But, my problem arise when you try to serve css from the same server.

https://github.com/Methrat0n/caldera-toy-project

Here is an example repository that can be used to reproduce the whole affair.
As you can see I'm using tailwind, but that should be unimportant in that matter as they generate a static css file at compile time.
The problem is located on the page load, Head does its job of writing to the head tag, but the call to retrieve that css is always answered with an index.html that, I assume, caldera did generate.

What I think is happening is that you catch all incoming request and always serve the caldera root, but that cannot work to support other ressources.
Maybe I'm missing something, I would be glad to know that caldera just work, but for the moment it seams to only support external css, as the examples shows.

@Methrat0n
Copy link
Author

This line seams to be the culprint, I'll try doing a PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant