Skip to content

fix(docs): move UnoCSS presets into uno.config.ts - #92

Merged
sergeysova merged 2 commits into
mainfrom
fix/docs-unocss-config
Jul 20, 2026
Merged

fix(docs): move UnoCSS presets into uno.config.ts#92
sergeysova merged 2 commits into
mainfrom
fix/docs-unocss-config

Conversation

@sergeysova

Copy link
Copy Markdown
Member

Problem

Every docs build logs, twice (client and server bundles):

[@unocss/config] Config file not found in .../docs - loading default config.

The UnoCSS presets were passed inline to the Vite plugin
(Unocss({ presets: [...] })), so UnoCSS's own config-file discovery found
nothing and fell back to an empty default config, logging the warning each time.

Fix

Move the presets into a standalone docs/uno.config.ts, which the Vite plugin
auto-loads, and call Unocss() with no arguments.

No change in output: the i-logos:typescript-icon on the landing still renders
(verified the generated CSS still contains the icon rule at scale: 1.2), and
the warning is gone.

The presets were passed inline to the Vite plugin, so UnoCSS's own config
discovery found no file and logged "config file not found in .../docs -
loading default config" on every build (twice — client and server bundles).
Moving them into a standalone uno.config.ts, which the plugin auto-loads,
silences the warning with no change in output (the logos:typescript-icon on
the landing still renders).
@bolt-new-by-stackblitz

Copy link
Copy Markdown

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@changeset-bot

changeset-bot Bot commented Jul 20, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 7fd422b

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

VitePress removes .temp on a normal build, but the DEBUG=1 workaround for the
Windows EBUSY rmdir bug leaves it behind — ignore it (and the cache dir) so it
can't be committed by accident.
@sergeysova
sergeysova merged commit 0d4c97f into main Jul 20, 2026
10 checks passed
@sergeysova
sergeysova deleted the fix/docs-unocss-config branch July 20, 2026 06:07
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.

1 participant