You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

@nuxt/vue-app

Package Overview
Dependencies
Maintainers
3
Versions
67
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nuxt/vue-app - npm Package Compare versions

Comparing version

to
2.11.0

10

dist/vue-app.js
/*!
* @nuxt/vue-app v2.10.2 (c) 2016-2019
* @nuxt/vue-app v2.11.0 (c) 2016-2019

@@ -19,9 +19,9 @@ * - All the amazing contributors

unfetch: "^4.1.0",
vue: "^2.6.10",
vue: "^2.6.11",
"vue-client-only": "^2.0.0",
"vue-meta": "^2.3.1",
"vue-no-ssr": "^1.1.1",
"vue-router": "~3.0.7",
"vue-template-compiler": "^2.6.10",
vuex: "^3.1.1"
"vue-router": "^3.1.3",
"vue-template-compiler": "^2.6.11",
vuex: "^3.1.2"
};

@@ -28,0 +28,0 @@

{
"name": "@nuxt/vue-app",
"version": "2.10.2",
"version": "2.11.0",
"repository": "nuxt/nuxt.js",

@@ -17,9 +17,9 @@ "license": "MIT",

"unfetch": "^4.1.0",
"vue": "^2.6.10",
"vue": "^2.6.11",
"vue-client-only": "^2.0.0",
"vue-meta": "^2.3.1",
"vue-no-ssr": "^1.1.1",
"vue-router": "~3.0.7",
"vue-template-compiler": "^2.6.10",
"vuex": "^3.1.1"
"vue-router": "^3.1.3",
"vue-template-compiler": "^2.6.11",
"vuex": "^3.1.2"
},

@@ -26,0 +26,0 @@ "publishConfig": {

@@ -32,5 +32,5 @@ import Vue from 'vue'

<% if (features.meta) { %>
<%= isTest ? '/* eslint-disable quotes, semi, indent, comma-spacing, key-spacing, object-curly-spacing, space-before-function-paren, object-shorthand */' : '' %>
<%= isTest ? '/* eslint-disable array-bracket-spacing, quotes, quote-props, semi, indent, comma-spacing, key-spacing, object-curly-spacing, space-before-function-paren, object-shorthand */' : '' %>
head: <%= serializeFunction(head) %>,
<%= isTest ? '/* eslint-enable quotes, semi, indent, comma-spacing, key-spacing, object-curly-spacing, space-before-function-paren, object-shorthand */' : '' %>
<%= isTest ? '/* eslint-enable array-bracket-spacing, quotes, quote-props, semi, indent, comma-spacing, key-spacing, object-curly-spacing, space-before-function-paren, object-shorthand */' : '' %>
<% } %>

@@ -41,8 +41,11 @@ render (h, props) {

<% if (components.ErrorPage) { %>
if (this.nuxt.err && NuxtError.layout) {
this.setLayout(
typeof NuxtError.layout === 'function'
? NuxtError.layout(this.context)
: NuxtError.layout
)
if (this.nuxt.err && NuxtError) {
const errorLayout = (NuxtError.options || NuxtError).layout
if (errorLayout) {
this.setLayout(
typeof errorLayout === 'function'
? errorLayout.call(NuxtError, this.context)
: errorLayout
)
}
}

@@ -56,3 +59,3 @@ <% } %>

key: this.layoutName
}, [ layoutEl ])
}, [layoutEl])
<% } else { %>

@@ -76,3 +79,3 @@ const templateEl = h('nuxt')

}
}, [ templateEl ])
}, [templateEl])
<% } %>

@@ -79,0 +82,0 @@

@@ -43,3 +43,3 @@ import Vue from 'vue'

const ssrLogSyle = 'background: #2E495E;border-radius: 0.5em;color: white;font-weight: bold;padding: 2px 0.5em;'
console.group && console.group<%= nuxtOptions.render.ssrLog === 'collapsed' ? 'Collapsed' : '' %> ("%cNuxt SSR", ssrLogSyle)
console.group && console.group<%= nuxtOptions.render.ssrLog === 'collapsed' ? 'Collapsed' : '' %> ('%cNuxt SSR', ssrLogSyle)
logs.forEach(logObj => (console[logObj.type] || console.log)(...logObj.args))

@@ -319,6 +319,7 @@ delete NUXT.logs

// Load layout for error page
const errorLayout = (NuxtError.options || NuxtError).layout
const layout = await this.loadLayout(
typeof NuxtError.layout === 'function'
? NuxtError.layout(app.context)
: NuxtError.layout
typeof errorLayout === 'function'
? errorLayout.call(NuxtError, app.context)
: errorLayout
)

@@ -335,3 +336,3 @@ <% } %>

// Show error page
app.context.error({ statusCode: 404, message: `<%= messages.error_404 %>` })
app.context.error({ statusCode: 404, message: '<%= messages.error_404 %>' })
return next()

@@ -413,3 +414,3 @@ }

if (!isValid) {
this.error({ statusCode: 404, message: `<%= messages.error_404 %>` })
this.error({ statusCode: 404, message: '<%= messages.error_404 %>' })
return next()

@@ -530,3 +531,3 @@ }

// Load error layout
let layout = NuxtError.layout
let layout = (NuxtError.options || NuxtError).layout
if (typeof layout === 'function') {

@@ -566,3 +567,3 @@ layout = layout(app.context)

let layout = this.$options.nuxt.err
? NuxtError.layout
? (NuxtError.options || NuxtError).layout
: to.matched[0].components.default.options.layout

@@ -569,0 +570,0 @@

@@ -95,2 +95,3 @@ import Vue from 'vue'

const Components = this.getPrefetchComponents()
<% if (router.linkPrefetchedClass) { %>const promises = []<% } %>

@@ -101,6 +102,8 @@ for (const Component of Components) {

componentOrPromise.catch(() => {})
<% if (router.linkPrefetchedClass) { %>promises.push(componentOrPromise)<% } %>
}
Component.__prefetched = true
}<% if (router.linkPrefetchedClass) { %>
this.addPrefetchedClass()<% } %>
return Promise.all(promises).then(() => this.addPrefetchedClass())
<% } %>
}<% if (router.linkPrefetchedClass) { %>,

@@ -107,0 +110,0 @@ addPrefetchedClass () {

@@ -31,3 +31,3 @@ import Vue from 'vue'

<%= isTest ? '// eslint-disable-next-line no-console' : '' %>
console.warn(`<no-ssr> has been deprecated and will be removed in Nuxt 3, please use <client-only> instead`)
console.warn('<no-ssr> has been deprecated and will be removed in Nuxt 3, please use <client-only> instead')
}

@@ -44,3 +44,3 @@ return NoSsr.render(h, ctx)

// Component: <Nuxt>`
// Component: <Nuxt>
Vue.component(Nuxt.name, Nuxt)

@@ -95,6 +95,6 @@

defaultTransition,
transitions: [ defaultTransition ],
transitions: [defaultTransition],
setTransitions (transitions) {
if (!Array.isArray(transitions)) {
transitions = [ transitions ]
transitions = [transitions]
}

@@ -143,3 +143,3 @@ transitions = transitions.map((transition) => {

} else {
const path = getLocation(router.options.base)
const path = getLocation(router.options.base, router.options.mode)
route = router.resolve(path).route

@@ -185,3 +185,3 @@ }

Vue.use(() => {
if (!Vue.prototype.hasOwnProperty(key)) {
if (!Object.prototype.hasOwnProperty.call(Vue, key)) {
Object.defineProperty(Vue.prototype, key, {

@@ -188,0 +188,0 @@ get () {

@@ -52,3 +52,3 @@ import Vue from 'vue'

res += (route.components) ? nextIndent + 'components: {' + resMap + '\n' + baseIndent + tab + '}' : ''
res += (route.component) ? nextIndent + 'component: ' + (splitChunks.pages ? route._name : `() => ${route._name}.default || ${route._name}`) : ''
res += (route.component) ? nextIndent + 'component: ' + route._name : ''
res += (route.redirect) ? nextIndent + 'redirect: ' + JSON.stringify(route.redirect) : ''

@@ -86,2 +86,9 @@ res += (route.meta) ? nextIndent + 'meta: ' + JSON.stringify(route.meta) : ''

// TODO: remove in Nuxt 3
const emptyFn = () => {}
const originalPush = Router.prototype.push
Router.prototype.push = function push (location, onComplete = emptyFn, onAbort) {
return originalPush.call(this, location, onComplete, onAbort)
}
Vue.use(Router)

@@ -95,5 +102,5 @@

scrollBehavior,
<%= isTest ? '/* eslint-disable quotes, object-curly-spacing, key-spacing */' : '' %>
<%= isTest ? '/* eslint-disable array-bracket-spacing, quotes, quote-props, object-curly-spacing, key-spacing */' : '' %>
routes: [<%= _routes %>],
<%= isTest ? '/* eslint-enable quotes, object-curly-spacing, key-spacing */' : '' %>
<%= isTest ? '/* eslint-enable array-bracket-spacing, quotes, quote-props, object-curly-spacing, key-spacing */' : '' %>
<% if (router.parseQuery) { %>parseQuery: <%= serializeFunction(router.parseQuery) %>,<% } %>

@@ -100,0 +107,0 @@ <% if (router.stringifyQuery) { %>stringifyQuery: <%= serializeFunction(router.stringifyQuery) %>,<% } %>

@@ -46,3 +46,3 @@ import { stringify } from 'querystring'

ssrContext.res.writeHead(opts.status, {
'Location': opts.path
Location: opts.path
})

@@ -92,3 +92,4 @@ ssrContext.res.end()

// Load layout for error page
const errLayout = (typeof NuxtError.layout === 'function' ? NuxtError.layout(app.context) : NuxtError.layout)
const layout = (NuxtError.options || NuxtError).layout
const errLayout = typeof layout === 'function' ? layout.call(NuxtError, app.context) : layout
ssrContext.nuxt.layout = errLayout || 'default'

@@ -102,3 +103,3 @@ await _app.loadLayout(errLayout)

const render404Page = () => {
app.context.error({ statusCode: 404, path: ssrContext.url, message: `<%= messages.error_404 %>` })
app.context.error({ statusCode: 404, path: ssrContext.url, message: '<%= messages.error_404 %>' })
return renderErrorPage()

@@ -105,0 +106,0 @@ }

@@ -11,5 +11,5 @@ import Vue from 'vue'

<% } %>
let store = {}
let store = {};
void (function updateModules () {
(function updateModules () {
<% storeModules.some(s => {

@@ -16,0 +16,0 @@ if(s.src.indexOf('index.') === 0) { %>

@@ -283,3 +283,3 @@ import Vue from 'vue'

export function compile (str, options) {
return tokensToFunction(parse(str, options))
return tokensToFunction(parse(str, options), options)
}

@@ -453,3 +453,3 @@

*/
function tokensToFunction (tokens) {
function tokensToFunction (tokens, options) {
// Compile all the tokens into regexps.

@@ -461,3 +461,3 @@ const matches = new Array(tokens.length)

if (typeof tokens[i] === 'object') {
matches[i] = new RegExp('^(?:' + tokens[i].pattern + ')$')
matches[i] = new RegExp('^(?:' + tokens[i].pattern + ')$', flags(options))
}

@@ -537,2 +537,12 @@ }

/**
* Get the flags for a regexp from the options.
*
* @param {Object} options
* @return {string}
*/
function flags (options) {
return options && options.sensitive ? '' : 'i'
}
/**
* Format given url, append query to url query string

@@ -539,0 +549,0 @@ *

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet