mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
ui build
This commit is contained in:
1 parent
9c45527522
commit
7dc31d02fa
15 files changed
+10521
-3
No files matched your search
+2
-3
@@ -31,8 +31,7 @@ const includedPages = pageLoader.getAutoloadPages();
|
||||
function buildSequence(pages, type) {
|
||||
if (process.env.NODE_ENV !== 'production') {
|
||||
if (['before', 'after'].indexOf(type) === -1) {
|
||||
// eslint-disable-next-line quotes
|
||||
throw new Error(`'type' should be one of 'before' or 'after'`);
|
||||
throw new Error(`'type' should be one of 'before' or 'after'`); // eslint-disable-line quotes
|
||||
}
|
||||
}
|
||||
return pages
|
||||
@@ -51,7 +50,7 @@ async function load() {
|
||||
...buildSequence(includedPages, 'after'),
|
||||
...buildSequence([currentPage], 'after'),
|
||||
];
|
||||
// eslint-disable-next-line no-restricted-syntax
|
||||
// eslint-disable-next-line no-restricted-syntax
|
||||
for (const { page, func, type } of loadSequence) {
|
||||
if (typeof func !== 'function') {
|
||||
if (process.env.NODE_ENV !== 'production') {
|
||||
|
||||
Reference in new issue
Block a user