Add serverless permalinking

This commit is contained in:
Sam Carlton 2021-07-24 14:30:33 -05:00
parent 93db24e5a3
commit a4c999048f

View file

@ -123,6 +123,7 @@ export class AppTemplate {
data: 'eleventy-endpoints', data: 'eleventy-endpoints',
size: 1, size: 1,
alias: 'app', alias: 'app',
serverless: 'eleventy.app.slug',
before: function( data ) { before: function( data ) {
return data.filter( entry => { return data.filter( entry => {
@ -149,7 +150,12 @@ export class AppTemplate {
permalink: ({ app }) => { permalink: ({ app }) => {
// console.log('payload', app.payload) // console.log('payload', app.payload)
return app.route.substring(1) + '/' return {
'build': app.route.substring(1) + '/',
'eleventy-builder': '/app/:slug/'//app.route.substring(1) + '/'
}
} }
} }
} }