-
-
Notifications
You must be signed in to change notification settings - Fork 8.5k
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
[v2] unable to use theme-classic without remark-admonitions #2525
Comments
This is weird, since we included admonitions in core (so there should be no errors with CSS file), how did you remove this module? |
@lex111 you don't include admonitions in core (see https://github.com/facebook/docusaurus/blob/master/packages/docusaurus/package.json#L34-L88) but include it only in preset-classic (https://github.com/facebook/docusaurus/blob/master/packages/docusaurus-preset-classic/package.json#L19) which I'm not using because I always avoid the preset. I think this theme should check if admonitions is enabled before trying to include that file. |
@phated aah, I get it, we did not consider the case when someone can use the classic theme directly without using the preset (this is not a very popular use case). |
@lex111 is there a reason that |
We should shift |
@phated I see that the Gulp website is already using the latest version of D2, which is awesome! Regarding this issue, why don't you use preset-classic? Even if you do not need a blog, this should not bring overhead. |
Yeah, we pushed through any issues because I needed to get it released before a podcast appearance this week. Docusaurus has been amazing, as always! I'm generally against presets for most tools I use because I end up needing to change a lot of things. For example, I see a world where the gulp team creates their own theme (we've done medium customization already and need more), so I wouldn't want to rip out the preset at that time. I also think by understanding how the preset is working and reimplementing it myself, I can see things that aren't needed and find issues like this. I have more feedback on the plugin architecture, but I currently don't have the time to write up my thoughts 🙁 |
@phated we really love the feedback from our users, thank you for that. We welcome any feedback, because we are still in the alpha stage. I tend to include admonitions in every plugin (both for docs and blogs), instead of doing this in a preset. I think it was a predictable behavior. BTW consider adding your project to our showcase at https://v2.docusaurus.io/showcase 😇 |
🐛 Bug Report
Due to https://github.com/facebook/docusaurus/blob/master/packages/docusaurus-theme-classic/src/index.js#L56, you are unable to to use the
@docusaurus/theme-classic
theme without installing theremark-admonitions
module. This shouldn't be a hard requirement.Have you read the Contributing Guidelines on issues?
Yep
To Reproduce
Expected behavior
The theme should be usable without external dependencies unless I opt-in.
Actual Behavior
Doesn't compile and is unusable without installing the
remark-admonitions
module.Your Environment
^2.0.0-alpha.50
Reproducible Demo
None currently because I'm trying to upgrade the gulp website...
The text was updated successfully, but these errors were encountered: