diff --git a/lib/nuxt.js b/lib/nuxt.js index e9f6e38fff..0e0c243133 100644 --- a/lib/nuxt.js +++ b/lib/nuxt.js @@ -143,6 +143,7 @@ class Nuxt { } const html = self.appTemplate({ dev: self.dev, // Use to add the extracted CSS in production + baseUrl: (self.options.router.base !== '/' ? self.options.router.base : null), APP: app, context: context, files: { diff --git a/lib/views/app.html b/lib/views/app.html index ddb22e0dd4..ed052bcc17 100644 --- a/lib/views/app.html +++ b/lib/views/app.html @@ -8,6 +8,7 @@ ${title.toString()} + <% if (baseUrl) { %><% } %> <% if (!dev) { %><% } %>