mirror of
https://github.com/actions/configure-pages.git
synced 2026-03-30 10:04:52 +00:00
Add tests that will fail with ECMA 6 parsing
This commit is contained in:
18
src/fixtures/nuxt/async.expected.js
Normal file
18
src/fixtures/nuxt/async.expected.js
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
const getAllDynamicRoute = async function() {
|
||||||
|
const routes = await (async () => {
|
||||||
|
return ['/posts/hello-world', '/posts/hello-again'];
|
||||||
|
})();
|
||||||
|
return routes;
|
||||||
|
};
|
||||||
|
|
||||||
|
export default {
|
||||||
|
target: 'static',
|
||||||
|
router: {base: '/docs/'},
|
||||||
|
mode: 'universal',
|
||||||
|
generate: {
|
||||||
|
async routes () {
|
||||||
|
return getAllDynamicRoute();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
15
src/fixtures/nuxt/async.js
Normal file
15
src/fixtures/nuxt/async.js
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
const getAllDynamicRoute = async function() {
|
||||||
|
const routes = await (async () => {
|
||||||
|
return ['/posts/hello-world', '/posts/hello-again'];
|
||||||
|
})();
|
||||||
|
return routes;
|
||||||
|
};
|
||||||
|
|
||||||
|
export default {
|
||||||
|
mode: 'universal',
|
||||||
|
generate: {
|
||||||
|
async routes () {
|
||||||
|
return getAllDynamicRoute();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
Reference in New Issue
Block a user