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

added automatic detection of css files #152

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bradley-erickson
Copy link

This commit adds automatic detection of css files in the distribution folder {{cookiecutter.project_shortname}}. The codes adds all *.css files to the MANIFEST.in file. Additionally, the code walks over the distribution folder to find each *.css file and append it to the _css_dist list in {{cookiecutter.project_shortname}}/__init__.py

Copy link

@emptynonsens emptynonsens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Working automatic css detection. One remark to README, so the information exists.

@@ -52,8 +52,6 @@ If you have selected install_dependencies during the prompt, you can skip this p
- Run the tests with `$ pytest tests`.
- The Dash team uses these types of integration tests extensively. Browse the Dash component code on GitHub for more examples of testing (e.g. https://github.com/plotly/dash-core-components)
- Add custom styles to your component by putting your custom CSS files into your distribution folder (`{{cookiecutter.project_shortname}}`).
- Make sure that they are referenced in `MANIFEST.in` so that they get properly included when you're ready to publish your component.
- Make sure the stylesheets are added to the `_css_dist` dict in `{{cookiecutter.project_shortname}}/__init__.py` so dash will serve them automatically when the component suite is requested.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This info might come in handy:

  • styles from the distribution folder are automatically referenced in 'MANIFEST.in' and the _css_dist dictionary in {{cookiecutter.project_shortname}}/init.py. If a custom reference is needed, make an analogous reference.

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.

2 participants