Commit graph

118 commits

Author SHA1 Message Date
Sébastien Lorber
9265de982b
chore(v2): refactor scripts + add theme-classic watchmode (#2998) 2020-07-01 18:30:44 +02:00
Sébastien Lorber
cf97662eef
fix(v2): refactor routes.ts + add route hash for chunkNames key (#3001)
* add simpleHash util

* refactor/split the routes generation logic + add route hash to avoid chunk conflicts

* minor fixes + fix tests

* fix comment typo
2020-06-30 11:52:39 +02:00
Teik Jun
2e055f4ae2
fix(v2): make client-redirect-plugin not baseUrl sensitive (#3010)
* feat(v2): use relative routes path in postBuild hook

* feat(v2): use relativeRoutesPath in other methods and modify tests

* fix(v2): fix D2 client redirects and tests

* feat(v2): add tests for relativeRoutesPaths

* fix(v2): fix some typos in configValidation

* fix(v2): fix an eslint warning and restart github action

* refactor(v2): create a removePrefix method

* refactor(v2): inline unnecessary method
2020-06-29 18:38:28 +02:00
Sam Zhou
5ccd24cc1f
feat(v2): Support swizzling TypeScript components (#2671)
* feat(v2): Support swizzling TypeScript components

* Add tsc --noEmit to tsc script in theme-classic

Now everything can pass the type checker! (although still a lot of any)

* Add tsconfig and types.d.ts to website

Improve developer experience.

As an example, I converted NotFound to tsx

* Apply type annotation suggestions

* Do not fallback to `getThemePath` if getTypeScriptThemePath is undefined

* Fix tsc

* Add module declaration for @theme-original/*

* Move babel cli to root package.json
2020-06-25 16:07:30 +02:00
Sam Zhou
6e43c9bd34
chore(v2): Fix more eslint errors (#2976) 2020-06-21 15:09:00 +08:00
Sam Zhou
3611c96f90
chore(v2): Fix a lot of eslint warnings (#2972) 2020-06-20 12:30:18 +08:00
slorber
16ba6e54b6 v2.0.0-alpha.58 2020-06-18 14:02:26 +02:00
Sébastien Lorber
b5d7c3a111
misc(v2): better dx: yarn clear, yarn watch, yarn serve (#2922)
* add clear + serve scripts

* add ability to launch all TS projects in --watch mode

* attempt to create a watch plugin

* use rimraf for clear script

* update watch plugin poc

* add start:v2:watch

* remove the watch plugin
2020-06-16 20:40:46 +08:00
Sébastien Lorber
68a1bb1ebf
Merge pull request #2793 from slorber/feature/client-side-redirects
feat(v2): docusaurus-plugin-client-redirects
2020-06-10 17:36:57 +02:00
slorber
6b507630e3 migrate useful helper functions to docusaurus-utils 2020-06-10 17:22:41 +02:00
Sébastien Lorber
1003a15d1f
polish(v2): improve Docusaurus 1 to 2 migration developer experience (#2884)
* improve markdown parsing errors by adding file path to error

* typo commit

* Add default nav item position to right (as v1)

* improve error when sidebar references unexisting document

* parseMarkdownFile: improve errors by providing hint about using "" to avoid parsing errors, if using special characters

* improve subcategory migration error for Unknown sidebar item type

* improve unrecognizedFields error

* typo

* fix inline snapshots

* improve the migration docs

* improve the migration docs

* improve migration doc

* Update migrating-from-v1-to-v2.md

Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
2020-06-06 11:16:50 +08:00
slorber
da8ccd0419 add isValidPathname 2020-06-03 15:40:10 +02:00
Alexey Pyltsyn
1b2744570b
fix(v2): strip images and footnotes for excerpt correctly (#2855) 2020-06-01 18:36:02 +08:00
Alexey Pyltsyn
d8ebe8b2e4 v2.0.0-alpha.56 2020-05-27 20:18:28 +03:00
Sam Zhou
33b60c6ba4
fix(v2): Consistently use 10.15.1 as the minimum required node version (#2819) 2020-05-27 23:18:48 +08:00
Alexey Pyltsyn
d94a549cfb v2.0.0-alpha.55 2020-05-19 13:55:03 +03:00
Alexey Pyltsyn
da0f865831
fix(v2): remove Markdown syntax from excerpt (#2701)
* fix(v2): remove Markdown syntax from excerpt

* Update snapshots

* Use Remark

* Switch to own solution
2020-05-18 19:57:03 +08:00
Alexey Pyltsyn
16dd08a690
refactor(v2): make semicolon optional in imports for excerpt (#2696) 2020-04-30 01:05:29 +08:00
Alexey Pyltsyn
753d117025 v2.0.0-alpha.54 2020-04-28 09:49:27 +03:00
Alexey Pyltsyn
d90fdb04d5 v2.0.0-alpha.53 2020-04-27 16:38:33 +03:00
Alexey Pyltsyn
7359945f52 v2.0.0-alpha.52 2020-04-27 16:30:15 +03:00
Alexey Pyltsyn
c9c5aedcb5 v2.0.0-alpha.51 2020-04-27 14:44:56 +03:00
Yangshun Tay
7d792840ba misc: prettier 2020-04-22 20:39:11 +08:00
Alexey Pyltsyn
84fa4be865
fix(v2): ignore import declarations in excerpt (#2380)
* fix(v2): ignore import declarations in excerpt

* Update index.ts

Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
2020-04-22 20:28:14 +08:00
Alexey Pyltsyn
1f00d15c74 chore(v2): fix code style (revert previous changes) 2020-04-05 17:38:12 +03:00
Alexey Pyltsyn
6965a668cd chore(v2): fix code style 2020-04-05 17:30:59 +03:00
Yangshun Tay
b07507c9cc
chore(v2): upgrade devDependencies (#2538)
* chore(v2): upgrade devDependencies

* chore(v2): upgrade devDependencies

* chore: prettier
2020-04-05 19:07:44 +08:00
Bartosz Kaszubowski
5d65facc81
refactor(v2): replace Lodash with single methods packages in utils (#2536) 2020-04-05 18:32:28 +08:00
Fanny
5e664a1f26
feat(v2): add edit url in post page (#2524)
* Add edit page url in docs

* feat(v2): Create EditPage component

* feat(v2): Improve component

* Add test

* çhore(v2): update description

* çhore(v2): update url

* fix(v2): test

* fix(v2): test

* feat(v2): change the prop of EditPage component

* chore(v2): Remove packages

* feat(v2): Update old tests

* chore(v2): fix package

* fix(v2): fix editUrl

* docs(v2): document editUrl

* --

* --

Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
2020-04-05 17:34:48 +08:00
Alexey Pyltsyn
c207c3ba31 v2.0.0-alpha.50 2020-04-02 21:00:47 +03:00
Sam Zhou
da7fd1a186
fix(v2): unbreak blog-only mode routing by deplicating starting forward slashes (#2497) 2020-04-02 11:02:44 +08:00
Yangshun Tay
409f169379 v2.0.0-alpha.49 2020-04-01 16:00:14 +08:00
Ramón Lamana
ed5a994c7e
fix(v2): properly dedupe forward slashes in the entire URL path (#2405) 2020-03-12 22:35:30 +08:00
Alexey Pyltsyn
38bb8c4ced v2.0.0-alpha.48 2020-03-09 01:46:10 +03:00
Alexey Pyltsyn
1dc1f21e91 v2.0.0-alpha.47 2020-03-08 23:40:44 +03:00
Alexey Pyltsyn
9d45993da2 v2.0.0-alpha.46 2020-03-08 23:29:42 +03:00
Alexey Pyltsyn
bbb465be02 v2.0.0-alpha.45 2020-03-08 23:07:13 +03:00
Yangshun Tay
1e09feb2db v2.0.0-alpha.44 2020-03-08 23:45:30 +08:00
Alexey Pyltsyn
68a5cd5df1
fix(v2): make proper path to pages in TS (#2334) 2020-02-27 09:59:02 +08:00
Yangshun Tay
32c1a92b17
chore: yearless copyright headers for source code (#2320)
* chore: yearless copyright headers for source code

* update snapshots
2020-02-25 23:12:28 +08:00
Yangshun Tay
996b115199
misc(v2): clean up comments in code (#2294) 2020-02-18 21:29:23 +08:00
Yangshun Tay
3056479ed2 v2.0.0-alpha.43 2020-02-18 18:54:39 +08:00
Yangshun Tay
8a96e0bff6 v2.0.0-alpha.42 2020-02-18 18:51:41 +08:00
Yangshun Tay
3ba753922e Revert "v2.0.0-alpha.42"
This reverts commit d48200be7d.
2020-02-18 18:47:36 +08:00
Alexey Pyltsyn
d48200be7d v2.0.0-alpha.42 2020-02-18 13:29:02 +03:00
Yangshun Tay
d39c301db8 v2.0.0-alpha.41 2020-02-16 23:03:18 +08:00
Jonathan Delgado
5cb3309790 feat(v2): allow for TypeScript pages and components (#2221) 2020-01-20 10:55:50 +08:00
Yangshun Tay
a38125a718
chore: drop support for node <10.9 (#2207)
* drop node <10.9 on 2020

* misc: add nvmrc

Co-authored-by: Endi <endiliey@gmail.com>
2020-01-12 13:24:11 +08:00
endiliey
dad50823b6 v2.0.0-alpha.40 2019-12-25 16:41:52 +07:00
endiliey
cfc313d7c7 v2.0.0-alpha.39 2019-12-07 13:18:13 +07:00