Open
Conversation
- Current system *does not work*: the build creates a `tailwind.config.js` file properly, but that file does not influence whether or not preflight styles actually get included. Something seems to be wrong with respect to when the postcss/tailwind files are run versus when the `tailwind.config.js` file is processed.
Contributor
|
I haven't given much thought on this, but maybe using Embroider Macros could help here. Note that Embroider Macros works with traditional ember-cli, it's not required to have embroider. https://github.com/embroider-build/embroider/tree/master/packages/macros |
Contributor
|
I'm wondering if there's a different approach we could take, where AddonDocs can make the different parts of its styling available to the host addon to app.import('ember-cli-addon-docs/styles/tailwind-base');
app.import('ember-cli-addon-docs/styles/tailwind-components');
app.import('ember-cli-addon-docs/styles/tailwind-utilities');
app.import('ember-cli-addon-docs/styles/component-styles'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pursuant to this comment from @samselikoff , I have been attempting to modify the build process to optionally include Tailwind's base/preflight styles. This PR makes an attempt at this. While I believe this is close, it does not currently work. Any suggestions would be greatly appreciated:
ember-cli-build.jsto creates atailwind.config.jsfile with the necessary configuration options set. However, despite the fact that this file is built properly, that file does not seem influence whether or not preflight styles actually get included.versus when the
tailwind.config.jsfile is processed.I decided to go ahead and post the PR up to see if anyone might be able to provide advice for how to tackle this build problem or even suggest completely different approaches for how to configure the
tailwinds.config.jsat build-time?