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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix including Debug CSS in the index template #4596

Merged
merged 2 commits into from
May 20, 2024

Conversation

belen-albeza
Copy link
Contributor

This replicates the behavior when we were building the app with Gulp, in which the debug CSS was only included in local development.

  • 馃拕 Reformat JS file and remove leftover code
  • 馃悰 Include debug css in local dev only

To test:

  1. Run the devenv and wait for the frontend-watch and frontend-shadow tabs to finish their jobs.
    2.grep for text/css in the resources/public/index.html file. Two <link> tags for CSS files should be included, one of them should be debug.css
$ cat resources/public/index.html | grep css
<link id="theme" href="css/main.css?ts=1715957540350" rel="stylesheet" type="text/css" />
<link href="css/debug.css?ts=1715957540350" rel="stylesheet" type="text/css" />
  1. Now with Ctrl+C stop the jobs in the frontend-watch and frontend-shadow tabs.
  2. Change to the frontend directory and build the app for production:
cd frontend
./scripts/build
  1. Check with grep that only a single CSS file is included in <link> tags in target/dist/index.html
cat target/dist/index.html | grep css
<link id="theme" href="css/main.css?ts=1715957714143" rel="stylesheet" type="text/css" />

@EvaMarco EvaMarco self-assigned this May 20, 2024
@EvaMarco EvaMarco merged commit b48d568 into develop May 20, 2024
1 check passed
@EvaMarco EvaMarco deleted the ladybenko-fix-debug-css-template branch May 20, 2024 07:34
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

Successfully merging this pull request may close these issues.

None yet

2 participants