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

Clarify configuration in CDN mode #521

Open
francislavoie opened this issue Nov 12, 2024 · 0 comments
Open

Clarify configuration in CDN mode #521

francislavoie opened this issue Nov 12, 2024 · 0 comments
Labels
📚 Documentation The documentation is lacking or missing something

Comments

@francislavoie
Copy link

Documentation Is:

Missing

Link to relevant page or pages

Please Explain in Detail...

I'm using twind like this:

<script src="https://cdn.twind.style" crossorigin></script>

I'm trying to figure out how to disable class hashing, cause I find it annoying during development to not be able to see the class names on my HTML. But when I try to use the following, all classes fail to apply:

twind.install({
	hash: false,
});

I assume the problem is the CDN mode automatically does an install call and has some defaults, so trying to install a second time breaks it, or uses the wrong defaults, not merging it with the built-in defaults.

Your Proposal for Changes

I'd like to see a section that shows how to apply certain config overrides without losing the "smart defaults".

Or maybe I misunderstand how to disable hashing, there's also a gap in the docs for hash, it's only listed in the API config that it takes a boolean type. I also saw the below for twind.run which suggests it should work to set it to false:

// For now no hashing - seems to break monaco
hash: false,

Alternatives considered

No response

@francislavoie francislavoie added the 📚 Documentation The documentation is lacking or missing something label Nov 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📚 Documentation The documentation is lacking or missing something
Projects
None yet
Development

No branches or pull requests

1 participant