perf/fix(v2): more efficient hot reload & consistent filegen (#1950)

* perf(v2): efficient hot reload, consistent generated file

* changelog

* more
This commit is contained in:
Endi 2019-11-08 16:14:14 +07:00 committed by Yangshun Tay
parent 87f864e5ba
commit e04c8f140f
7 changed files with 60 additions and 6 deletions

View file

@ -18,9 +18,6 @@ import {posixPath} from '@docusaurus/utils';
const createFakeActions = (routeConfigs: RouteConfig[], contentDir) => {
return {
addRoute: (config: RouteConfig) => {
config.routes.sort((a, b) =>
a.path > b.path ? 1 : b.path > a.path ? -1 : 0,
);
routeConfigs.push(config);
},
createData: async (name, _content) => {