From 7529d65d75a1f943817cd5683e21335d48891b6b Mon Sep 17 00:00:00 2001 From: Pooya Parsa Date: Tue, 22 Dec 2020 18:20:41 +0100 Subject: [PATCH] chore: migrate from @nuxt/ufo to ufo --- packages/config/package.json | 2 +- packages/config/src/options.js | 2 +- packages/utils/package.json | 2 +- packages/utils/src/route.js | 2 +- packages/vue-app/package.js | 2 +- packages/vue-app/package.json | 2 +- packages/vue-app/template/App.js | 2 +- packages/vue-app/template/router.js | 2 +- packages/vue-app/template/server.js | 2 +- packages/vue-app/template/utils.js | 2 +- packages/vue-renderer/package.json | 2 +- packages/vue-renderer/src/renderer.js | 2 +- packages/vue-renderer/src/renderers/ssr.js | 2 +- 13 files changed, 13 insertions(+), 13 deletions(-) diff --git a/packages/config/package.json b/packages/config/package.json index 6c031e8e5d..6228bd0694 100644 --- a/packages/config/package.json +++ b/packages/config/package.json @@ -10,7 +10,7 @@ "index.d.ts" ], "dependencies": { - "@nuxt/ufo": "^0.5.2", + "ufo": "^0.5.2", "@nuxt/utils": "2.14.12", "consola": "^2.15.0", "create-require": "^1.1.1", diff --git a/packages/config/src/options.js b/packages/config/src/options.js index 8820c29b8d..7b2f42bb79 100644 --- a/packages/config/src/options.js +++ b/packages/config/src/options.js @@ -5,7 +5,7 @@ import defu from 'defu' import consola from 'consola' import destr from 'destr' import { TARGETS, MODES, guardDir, isNonEmptyString, isPureObject, isUrl, getMainModule, getPKG } from '@nuxt/utils' -import { joinURL, normalizeURL, withTrailingSlash } from '@nuxt/ufo' +import { joinURL, normalizeURL, withTrailingSlash } from 'ufo' import { defaultNuxtConfigFile, getDefaultNuxtConfig } from './config' export function getNuxtConfig (_options) { diff --git a/packages/utils/package.json b/packages/utils/package.json index 1e7f1146f1..c5d52ca079 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -8,7 +8,7 @@ "dist" ], "dependencies": { - "@nuxt/ufo": "^0.5.2", + "ufo": "^0.5.2", "consola": "^2.15.0", "create-require": "^1.1.1", "fs-extra": "^9.0.1", diff --git a/packages/utils/src/route.js b/packages/utils/src/route.js index 91eb29640f..f94c8539fa 100644 --- a/packages/utils/src/route.js +++ b/packages/utils/src/route.js @@ -1,7 +1,7 @@ import path from 'path' import { get } from 'lodash' import consola from 'consola' -import { normalizeURL, withTrailingSlash, withoutTrailingSlash } from '@nuxt/ufo' +import { normalizeURL, withTrailingSlash, withoutTrailingSlash } from 'ufo' import { r } from './resolve' const routeChildren = function (route) { diff --git a/packages/vue-app/package.js b/packages/vue-app/package.js index 96cdfb3009..d4ffcffe70 100644 --- a/packages/vue-app/package.js +++ b/packages/vue-app/package.js @@ -2,7 +2,7 @@ export default { build: true, ignoreUnused: [ // used in vue-app - '@nuxt/ufo', + 'ufo', 'node-fetch', 'unfetch', 'vue', diff --git a/packages/vue-app/package.json b/packages/vue-app/package.json index 8472d5ece6..fdca10154f 100644 --- a/packages/vue-app/package.json +++ b/packages/vue-app/package.json @@ -13,7 +13,7 @@ "index.d.ts" ], "dependencies": { - "@nuxt/ufo": "^0.5.2", + "ufo": "^0.5.2", "node-fetch": "^2.6.1", "unfetch": "^4.2.0", "vue": "^2.6.12", diff --git a/packages/vue-app/template/App.js b/packages/vue-app/template/App.js index a5dba80e74..c51d2fa982 100644 --- a/packages/vue-app/template/App.js +++ b/packages/vue-app/template/App.js @@ -1,5 +1,5 @@ import Vue from 'vue' -import { parsePath, withoutTrailingSlash } from '@nuxt/ufo' +import { parsePath, withoutTrailingSlash } from 'ufo' <% utilsImports = [ ...(features.asyncData || features.fetch) ? [ 'getMatchedComponentsInstances', diff --git a/packages/vue-app/template/router.js b/packages/vue-app/template/router.js index 86becdff01..b761d9f88b 100644 --- a/packages/vue-app/template/router.js +++ b/packages/vue-app/template/router.js @@ -1,6 +1,6 @@ import Vue from 'vue' import Router from 'vue-router' -import { normalizeURL, decode } from '@nuxt/ufo' +import { normalizeURL, decode } from 'ufo' import { interopDefault } from './utils'<%= isTest ? '// eslint-disable-line no-unused-vars' : '' %> import scrollBehavior from './router.scrollBehavior.js' diff --git a/packages/vue-app/template/server.js b/packages/vue-app/template/server.js index d449ce8eaa..c6250caca8 100644 --- a/packages/vue-app/template/server.js +++ b/packages/vue-app/template/server.js @@ -1,6 +1,6 @@ import { stringify } from 'querystring' import Vue from 'vue' -import { normalizeURL } from '@nuxt/ufo' +import { normalizeURL } from 'ufo' <% if (fetch.server) { %>import fetch from 'node-fetch'<% } %> <% if (features.middleware) { %>import middleware from './middleware.js'<% } %> import { diff --git a/packages/vue-app/template/utils.js b/packages/vue-app/template/utils.js index 3390c53de2..ad54b9650f 100644 --- a/packages/vue-app/template/utils.js +++ b/packages/vue-app/template/utils.js @@ -1,5 +1,5 @@ import Vue from 'vue' -import { normalizeURL } from '@nuxt/ufo' +import { normalizeURL } from 'ufo' // window.{{globals.loadedCallback}} hook // Useful for jsdom testing or plugins (https://github.com/tmpvar/jsdom#dealing-with-asynchronous-script-loading) diff --git a/packages/vue-renderer/package.json b/packages/vue-renderer/package.json index 3aabeb0ed6..03a8f99b11 100644 --- a/packages/vue-renderer/package.json +++ b/packages/vue-renderer/package.json @@ -9,7 +9,7 @@ ], "dependencies": { "@nuxt/devalue": "^1.2.4", - "@nuxt/ufo": "^0.5.2", + "ufo": "^0.5.2", "@nuxt/utils": "2.14.12", "consola": "^2.15.0", "fs-extra": "^9.0.1", diff --git a/packages/vue-renderer/src/renderer.js b/packages/vue-renderer/src/renderer.js index 598331c6bb..1fc27f9fe3 100644 --- a/packages/vue-renderer/src/renderer.js +++ b/packages/vue-renderer/src/renderer.js @@ -3,7 +3,7 @@ import fs from 'fs-extra' import consola from 'consola' import { template } from 'lodash' import { TARGETS, isModernRequest, urlJoin, waitFor } from '@nuxt/utils' -import { normalizeURL } from '@nuxt/ufo' +import { normalizeURL } from 'ufo' import SPARenderer from './renderers/spa' import SSRRenderer from './renderers/ssr' diff --git a/packages/vue-renderer/src/renderers/ssr.js b/packages/vue-renderer/src/renderers/ssr.js index c1adaf1531..aef6bcb9d7 100644 --- a/packages/vue-renderer/src/renderers/ssr.js +++ b/packages/vue-renderer/src/renderers/ssr.js @@ -4,7 +4,7 @@ import { format } from 'util' import fs from 'fs-extra' import consola from 'consola' import { TARGETS, urlJoin } from '@nuxt/utils' -import { parsePath, withoutTrailingSlash } from '@nuxt/ufo' +import { parsePath, withoutTrailingSlash } from 'ufo' import devalue from '@nuxt/devalue' import { createBundleRenderer } from 'vue-server-renderer' import BaseRenderer from './base'