Evan You
8288168b4f
adjust type exports
3 years ago
Evan You
6f3a96f06d
perf: do not include head config in client bundle for production
3 years ago
Evan You
6120da25a8
feat: properly remove custom anchor in headers
3 years ago
Evan You
294b1d2817
refactor: make MarkdowRenderer type compatible with MarkdownIt
3 years ago
Evan You
a4b7758a00
chore: tweak temp dir name
3 years ago
Evan You
4cec660401
feat: expose __path and __relativePath on md instance for md plugins
3 years ago
Evan You
7387649ff7
feat: catch localhost links as dead links
3 years ago
Gordon Smith
08a0b12992
fix(serve): respect base config in serve mode ( #470 )
...
Fixes #416
Signed-off-by: Gordon Smith <GordonJSmith@gmail.com>
3 years ago
Jeff Yang
a8f147f153
feat: add details custom container ( #455 )
3 years ago
Bryan Müller
5b04bb9eb5
feat: user configurable `outDir` ( #448 )
3 years ago
Jeff Yang
fb6a4ad3e0
fix: remove `.` for mjs in `supportedConfigExtensions` ( #447 )
3 years ago
Jonas
bd35451ed4
fix: set tempDir outside package root ( #439 )
...
package root can be read-only when install strategies like PnP are used, so the tempDir needs to be outside the vitepress package itself
close #435
3 years ago
fuchunhui
ae029ae9e1
fix: Chinese file link build failed ( #425 )
...
fix #424
3 years ago
ULIVZ
ba41bb9055
feat: improve typescript support for config file ( #465 )
3 years ago
Evan You
e61db62a1c
feat: minify head inline scripts
3 years ago
Evan You
e721d60585
feat: shouldPreload hook
3 years ago
Evan You
f5308d746f
feat: support array of patterns in data loaders
3 years ago
Evan You
6ca3c97ab9
fix duplicated preload directive
3 years ago
Evan You
26fe81c886
feat: support static data loaders
3 years ago
Evan You
d54c7d8c56
feat: expose createMarkdownRenderer
3 years ago
Evan You
dfa7c0525f
fix: handle potential string quote mismatch in generated code
3 years ago
Evan You
bc486aae56
fix: static string strip regex for mulitiline static strings
...
this can happen when the template contains `<pre>` tags
3 years ago
Evan You
abb1b578cd
fix: improve createStaticVNode match for rollup codegen compat
3 years ago
Evan You
a051e66f1a
fix: lazy require @vitejs/plugin-vue to respect NODE_ENV
3 years ago
Evan You
4114674c69
fix(hmr): avoid relying on revertd vite hmr behavior
3 years ago
Evan You
773472d867
chore: remove unnecessary log
3 years ago
Evan You
d3b1521ebe
feat: support ts/esm config file + defineConfig() helper
...
close #339 , close #376
3 years ago
Evan You
4c042b61e7
fix: fix code line hightlighting
...
close #408
3 years ago
宋铄运 (Alan Song)
4b76617621
fix: support vite plugins provided via `config.vite` ( #394 )
3 years ago
Evan You
df69b76427
fix: print urls again
3 years ago
Evan You
ba85fd4d51
chore: cleanup deps
3 years ago
CHOYSEN
58663bbd02
fix: make config hmr work in window ( #364 )
3 years ago
Anthony Fu
49ddb1f120
workflow: switch to pnpm ( #401 )
3 years ago
Evan You
3940625121
fix: encode urls that conflict w/ vite built-in replacements
3 years ago
Evan You
b3a4c52191
refactor: fix bad requires
3 years ago
Evan You
475dee5154
build: pre-bundle, reduce deps
3 years ago
Evan You
9030486409
feat: upgrade vue, simplify deps
3 years ago
Evan You
b59f54abd0
chore: remove debug hash log
3 years ago
QiChang Li
610e9b7111
feat: use `markdown-it-attrs` for markdown-it plugins ( #393 )
3 years ago
Evan You
929bcf50ee
fix: ensure stable pages entry order across builds
3 years ago
Evan You
e0b69973f8
feat: support `<script client>` in mpa mode
3 years ago
Evan You
b94b163a3a
feat: map mode + remove deprecated options
3 years ago
Evan You
6085501acb
chore: remove customData option
3 years ago
Evan You
f749b272d4
feat: support config.extends
3 years ago
Evan You
2e9264f032
fix: improve fs allow
3 years ago
Evan You
e01b5a350c
chore: typo
3 years ago
Sam Pullman
80ff36066e
fix: include emoji text in nav link to match toc ( #284 )
3 years ago
Eduardo San Martin Morote
26b5aa931f
feat: upgrade markdown-it-anchor ( #350 )
...
BREAKING CHANGE: the `markdown.anchor` option is updated. Refer to
valeriangalliat/markdown-it-anchor#permalinks for
instructions to upgrade your existing `markdown.anchor.permalink`
option. **This doesn't affect you if you weren't changing the header
permalinks behavior**.
3 years ago
Eduardo San Martin Morote
9b9fdc710a
fix: allow vite server access to theme and local files
3 years ago
Eduardo San Martin Morote
bc78adb468
fix(i18n): fix locales reading, add site.langs ( #353 )
...
It works with the same config as Vuepress 1: https://vuepress.vuejs.org/guide/i18n.html#site-level-i18n-config
We could probably adapt the `label` property like Vuepress 2 https://v2.vuepress.vuejs.org/guide/i18n.html#site-i18n-config in a next release
3 years ago
Eduardo San Martin Morote
858c0e77a0
build: rename carbon and buysell chunks ( #370 )
3 years ago
Evan You
7b3a9e59b4
feat: support partial include directive
3 years ago
Evan You
e74c5f06d1
feat: support function config
3 years ago
Evan You
4925fb5c29
feat: info custom container
3 years ago
Eduardo San Martin Morote
4a34b93090
refactor: reuse regexp
3 years ago
Eduardo San Martin Morote
7b501293da
chore: up deps
3 years ago
FangYing
aa9f9094b5
chore: remove log ( #331 )
...
Co-authored-by: Eduardo San Martin Morote <posva@users.noreply.github.com>
3 years ago
Evan You
3cec536c1f
fix: automatically escape vite user defined variables in markdown
3 years ago
Evan You
e6bb5a4806
perf: only update necessary head tags in prod
3 years ago
Evan You
348f19a537
fix: watch config file when using srcDir
3 years ago
Evan You
eefba398b0
fix: force optimize vue to avoid duplication when linked
3 years ago
Evan You
fbcb07eaab
chore: remove unused arg
3 years ago
Evan You
f5d0e1881c
chore: deprecation warnings
3 years ago
Evan You
aaf4910d93
feat: support srcDir config option
3 years ago
Evan You
3737b1055d
feat: support passing vite config in vitepress config file via `vite` option
...
BREAKING CHANGE: Some config options have changed.
- `vueOptions` renamed to `vue`
- `alias` option has been removed. Use `vite.resovle.alias` instead.
3 years ago
Evan You
5733fc625e
perf: avoid double resolve user config on startup
3 years ago
Evan You
55de7ab43c
refactor: adjust shared utility/types build setup
...
fix non-existent imports in generated dts files
3 years ago
Han(ハン)
71a5e1c2a2
feat: exclude option ( #281 )
3 years ago
Anthony Fu
9f1b2b1ae2
chore: update deps
3 years ago
Máximo Mussini
e651f977d6
feat: Render titles for social sharing and improve home page sharing ( #263 )
3 years ago
云游君
3aa185fa9f
fix: detect public folder for dead link ( #290 )
...
* fix: detect public folder for dead link
* perf: use config.publicDir replace 'public'
3 years ago
Domantas
fa469fd275
fix: build fails without css chunks ( #209 ) ( #239 )
...
Co-authored-by: Kia King Ishii <kia.king.08@gmail.com>
3 years ago
Babu Annamalai
d1a62e1c66
feat: import code snippet with region ( #237 ) ( #238 )
...
close #237
Co-authored-by: Kia King Ishii <kia.king.08@gmail.com>
3 years ago
meteorlxy
cee0b400d9
refactor: remove extra condition ( #261 )
4 years ago
Eduardo San Martin Morote
9bc5c5c631
style: format code with prettier
4 years ago
Evan You
74f5adafcd
feat: detect dead links
4 years ago
Evan You
c0aa5a8fae
deps: bump vite + update alias usage
4 years ago
hcg1023
2aa8ab26e2
fix: `@` alias for import code snippet being always `undefined` ( #204 )
...
Co-authored-by: Kia King Ishii <kia.king.08@gmail.com>
4 years ago
Kia King Ishii
72e116c2db
style: adjust import order a bit
4 years ago
Christopher Shank
5b34c6a94a
feat: add vue options config (expose @vitejs/plugin-vue) ( #215 )
4 years ago
Kia King Ishii
b82d8f2ece
fix: utf-8 character not working on safari in dev mode ( #228 )
4 years ago
NAN
8a0db65a8a
fix: render document with standards mode in dev ( #207 )
4 years ago
Matias Capeletto
338e8453d8
fix: frontmatter description duplication ( #194 ) ( #170 )
...
Co-authored-by: Kia King Ishii <kia.king.08@gmail.com>
4 years ago
Kia King Ishii
0b5b306f85
fix: `base` option not working on dev mode ( #223 )
4 years ago
Domantas
1026a20488
dx: replace . with / at the end of served url ( #210 )
4 years ago
Evan You
8e0b8d184a
chore: exclude docsearch from optimization
4 years ago
Evan You
8cfdd1912d
fix: update base option usage
4 years ago
Łukasz Romanowicz
51906043d3
fix: support symbolic links in building docs dist ( #184 ) ( #185 )
...
fix #184
4 years ago
Evan You
b4bdaf648d
refactor: vite ssr compat
4 years ago
Evan You
b9fc0cb78d
perf: generate preload directives for dynamicImport chunks too
4 years ago
Evan You
a79e1e1916
refactor: move default theme to 'vitepress/theme'
...
Fixes the case when using a completely custom theme, importing anything
from vitepress causes the entire default theme to be imported too.
BREAKING CHANGE: the default theme is now exposed via 'vitepress/theme',
instead of a named export from 'vitepress'.
4 years ago
Evan You
4072dc5f7e
feat: support customData in config
4 years ago
Evan You
9c7906119e
refactor: rename site alias
4 years ago
Anthony Fu
bac1ce2d01
fix: resolve page hash case-insenstively, close #202 ( #203 )
4 years ago
Evan You
64a08b35a3
chore: bump vite again
4 years ago
Evan You
759bbd3f61
chore: bump vite
4 years ago
Evan You
9965ce6ae8
pass ssr option to vite build
...
this will be required in next release
4 years ago
Matias Capeletto
da2c4f694e
fix: bump vite and fix win32 path resolving ( #198 )
4 years ago
Evan You
991a443c70
fix: vite 2.0.0-beta.2 compat
4 years ago
Evan You
d6b8568c52
fix: ensure the same vue dep in all cases
4 years ago
Evan You
055e3fd043
fix: respect root during build
4 years ago
Evan You
a41928ef83
fix: avoid unexpected vite define replacements in markdown content
4 years ago
Evan You
8769b4b49f
fix: always define theme globals
4 years ago
Evan You
4f0c90311f
refactor: simplify client path mapping
4 years ago
Evan You
04dc058cd9
fix: disable css code split
4 years ago
Evan You
e3d7fc0353
fix: minify
4 years ago
Evan You
2d77eafe3b
feat: production ready serve
4 years ago
Evan You
60d86e13ef
chore: use different port for serve
4 years ago
Evan You
c878e6d3b5
perf: avoid including optional features in build when not used
4 years ago
Evan You
22e12b8928
chore: bump min node version + target es2019
4 years ago
Evan You
b50a2dffc4
wip: make build pass
4 years ago
Evan You
04ed45d250
wip: serve w/ new impl
4 years ago
Evan You
d02cd6b9b5
wip: build compat for vite 2.0
4 years ago
Evan You
084c7deb02
wip: handle config hmr
4 years ago
Evan You
bf8fd3a6f3
wip: dev works with vite 2
4 years ago
Anthony Fu
cb306fa911
refactor: use ts for cli ( #191 )
4 years ago
Matias Capeletto
dd312ce86b
fix: port fixes to parseHeader utils from vuepress ( #172 )
4 years ago
Harlan Wilton
18d18d2eb1
fix(md): avoid normalising markdown "mailto:" links ( #173 )
...
The "mailto:" links were being normalised which resulted in them being linking to a broken URL and not working.
4 years ago
Anthony Fu
5fc2ee09cd
chore: typo
4 years ago
Evan You
b8e892e94a
feat: support customizing default theme via slots
...
Example:
```js
// .vitepress/theme/index.js
import { h } from 'vue'
import { defaultTheme } from 'vitepress'
const BaseLayout = defaultTheme.Layout
defaultTheme.Layout = () => {
return h(BaseLayout, null, {
'page-top-ads': () => h('h2', 'top ads!'),
'page-bottom-ads': () => h('h2', 'bottom ads!'),
})
}
export default defaultTheme
```
4 years ago
Evan You
2bb40d2875
refactor: better chunk filenames
4 years ago
Matias Capeletto
c6bdcfbf4f
feat!: add more global and computed properties ( #152 )
...
BREAKING CHANGE: `$theme` global computed is renamed to `$themeConfig`
to align better with VuePress.
Co-authored-by: Kia King Ishii <kia.king.08@gmail.com>
4 years ago
Evan You
b127aeeaf1
refactor: migrate default theme to use script-setup ( #137 )
...
Co-authored-by: Kia King Ishii <kia.king.08@gmail.com>
4 years ago
NAN
2d67db5642
chore: fix typo ( #141 )
4 years ago
Kia King Ishii
8735fc3096
test: add unit test setup ( #138 )
4 years ago
Kia King Ishii
fdd498be70
fix: fix next and prev links not working ( #130 )
4 years ago
Kia King Ishii
67868bd928
feat: add serve command ( #136 )
4 years ago
Kia King Ishii
9ab63e1742
refactor(build): remove duplicated `done` message at the end of build
4 years ago
Evan You
e435eec94a
feat: better build command output
4 years ago
Christopher Shank
463a03a981
feat: add ability to configure markdown options ( #127 ) ( #128 )
...
close #127
Co-authored-by: Kia Ishii <kia.king.08@gmail.com>
4 years ago
Kia King Ishii
df97d96909
build: handle shared files better ( #72 ) ( #114 )
...
fix #72
4 years ago
Evan You
6b3fbe31a3
fix: adapt to vite fix of ssr build asset paths
4 years ago
Evan You
b10da2f47b
fix: compat with latest vite + handle no export default script tags in md
4 years ago
Eduardo San Martin Morote
02f2e10f89
feat: add doctype html
4 years ago
tanasinn
0ea34cbb1d
feat: add git repo link and edit links ( #55 )
...
Co-authored-by: Shintaro Tanaka <s-tanaka@holmescloud.com>
Co-authored-by: Eduardo San Martin Morote <posva@users.noreply.github.com>
4 years ago
Eduardo San Martin Morote
4e4770169d
refactor(server): add types and fix out of bounds next/previous
4 years ago
Kia King Ishii
5538af6d3d
style: fix broken indent
4 years ago
Kia King Ishii
2e8e1f57cc
feat: add charset and viewport meta tags ( #77 )
4 years ago
em2046
63a3691960
feat: support config alias ( #59 )
4 years ago
Yugo Ogura
f52b1d576b
feat: add prev/next links ( #56 )
...
* feat: set Prev/Next to page data
* feat: set links at the bottom of page
* feat: hide next/prev links when themeConfig expressly set false
4 years ago
Anthony Fu
7802cb55c2
feat: i18n support ( #50 )
4 years ago
Evan You
e77ea63237
fix: avoid error when requesting non-existing md file
4 years ago
Kia King Ishii
4a8388e113
feat: add array sidebar support ( #35 )
4 years ago
Eduardo San Martin Morote
6f10ed6c63
fix: use resolve instead of join ( #33 )
...
Allows the documentation to exist in a folder e.g. `docs`, and running `vitepress dev
docs` as well as `vitepress build docs`
4 years ago
Carlos Rodrigues
9116c9c3e0
fix: resolve relative path on windows ( #27 )
4 years ago
Evan You
a7db9a79be
upgrade to vite 1.0 beta
4 years ago
Evan You
bad7b4a33a
bump vite, remove no longer needed watch logic
4 years ago
Evan You
9a795389b9
bump vite + use simpler directory aliasing
4 years ago
Evan You
1be0a0b0a1
wip: default theme
4 years ago
Evan You
382e1b6514
fix: lazy load @vue/server-render for production build
4 years ago
Evan You
255a2c4853
wip: theme
4 years ago
Evan You
dcae3f330d
wip: default theme
4 years ago
Evan You
a5e3d5d2f5
wip: migrate client to typescript
4 years ago