Merge branch 'main' into unused-deps

This commit is contained in:
James M. Greene
2022-09-26 10:58:37 -05:00
23 changed files with 4007 additions and 202 deletions

17
.eslintrc.json Normal file
View File

@@ -0,0 +1,17 @@
{
"env": {
"commonjs": true,
"es2021": true,
"node": true,
"jest": true
},
"plugins": ["github"],
"extends": ["eslint:recommended", "prettier", "plugin:github/internal"],
"parserOptions": {
"ecmaVersion": 12
},
"rules": {
"semi": ["error", "never"]
},
"ignorePatterns": ["/dist/", "/src/fixtures/", "/src/blank-configurations/"]
}

View File

@@ -1,6 +1,6 @@
--- ---
name-template: "v$RESOLVED_VERSION" name-template: 'v$RESOLVED_VERSION'
tag-template: "v$RESOLVED_VERSION" tag-template: 'v$RESOLVED_VERSION'
template: | template: |
# Changelog # Changelog
@@ -8,33 +8,33 @@ template: |
See details of [all code changes](https://github.com/$OWNER/$REPOSITORY/compare/$PREVIOUS_TAG...v$RESOLVED_VERSION) since previous release. See details of [all code changes](https://github.com/$OWNER/$REPOSITORY/compare/$PREVIOUS_TAG...v$RESOLVED_VERSION) since previous release.
categories: categories:
- title: "🚀 Features" - title: '🚀 Features'
labels: labels:
- "feature" - 'feature'
- "enhancement" - 'enhancement'
- title: "🐛 Bug Fixes" - title: '🐛 Bug Fixes'
labels: labels:
- "fix" - 'fix'
- "bugfix" - 'bugfix'
- "bug" - 'bug'
- title: "🧰 Maintenance" - title: '🧰 Maintenance'
labels: labels:
- "infrastructure" - 'infrastructure'
- "automation" - 'automation'
- "documentation" - 'documentation'
- title: "🏎 Performance" - title: '🏎 Performance'
label: "performance" label: 'performance'
change-template: "- $TITLE @$AUTHOR (#$NUMBER)" change-template: '- $TITLE @$AUTHOR (#$NUMBER)'
version-resolver: version-resolver:
major: major:
labels: labels:
- "type: breaking" - 'type: breaking'
minor: minor:
labels: labels:
- "type: enhancement" - 'type: enhancement'
patch: patch:
labels: labels:
- "type: bug" - 'type: bug'
- "type: maintenance" - 'type: maintenance'
- "type: documentation" - 'type: documentation'
default: patch default: patch

View File

@@ -1,4 +1,4 @@
name: Checking formatting name: Check formatting
on: on:
push: push:
@@ -17,11 +17,12 @@ concurrency:
jobs: jobs:
test: test:
runs-on: ubuntu-latest runs-on: ubuntu-latest
timeout-minutes: 2
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v3 uses: actions/checkout@v3
- name: Setup Node.JS - name: Setup Node
uses: actions/setup-node@v3 uses: actions/setup-node@v3
with: with:
node-version: 16.x node-version: 16.x

35
.github/workflows/lint.yml vendored Normal file
View File

@@ -0,0 +1,35 @@
name: Lint code
on:
push:
branches:
- main
pull_request:
permissions:
contents: read
# This allows a subsequently queued workflow run to interrupt previous runs
concurrency:
group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
cancel-in-progress: true
jobs:
lint:
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- name: Check out repo
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 16.x
cache: npm
- name: Install dependencies
run: npm ci
- name: Run linter
run: npm run lint:check

View File

@@ -5,7 +5,7 @@ on:
workflow_dispatch: workflow_dispatch:
inputs: inputs:
TAG_NAME: TAG_NAME:
description: "Tag name that the major tag will point to" description: 'Tag name that the major tag will point to'
required: true required: true
env: env:

5
.prettierignore Normal file
View File

@@ -0,0 +1,5 @@
# Ignore build artifacts
/dist/
# Ignore all Markdown files
*.md

137
dist/index.js vendored
View File

@@ -2836,10 +2836,10 @@ module.exports = {
var defaultOptions = { var defaultOptions = {
// `ecmaVersion` indicates the ECMAScript version to parse. Must be // `ecmaVersion` indicates the ECMAScript version to parse. Must be
// either 3, 5, 6 (or 2015), 7 (2016), 8 (2017), 9 (2018), 10 // either 3, 5, 6 (or 2015), 7 (2016), 8 (2017), 9 (2018), 10
// (2019), 11 (2020), 12 (2021), 13 (2022), or `"latest"` (the // (2019), 11 (2020), 12 (2021), 13 (2022), 14 (2023), or `"latest"`
// latest version the library supports). This influences support // (the latest version the library supports). This influences
// for strict mode, the set of reserved words, and support for // support for strict mode, the set of reserved words, and support
// new syntax features. // for new syntax features.
ecmaVersion: null, ecmaVersion: null,
// `sourceType` indicates the mode the code should be parsed in. // `sourceType` indicates the mode the code should be parsed in.
// Can be either `"script"` or `"module"`. This influences global // Can be either `"script"` or `"module"`. This influences global
@@ -2873,8 +2873,9 @@ module.exports = {
// When enabled, super identifiers are not constrained to // When enabled, super identifiers are not constrained to
// appearing in methods and do not raise an error when they appear elsewhere. // appearing in methods and do not raise an error when they appear elsewhere.
allowSuperOutsideMethod: null, allowSuperOutsideMethod: null,
// When enabled, hashbang directive in the beginning of file // When enabled, hashbang directive in the beginning of file is
// is allowed and treated as a line comment. // allowed and treated as a line comment. Enabled by default when
// `ecmaVersion` >= 2023.
allowHashBang: false, allowHashBang: false,
// When `locations` is on, `loc` properties holding objects with // When `locations` is on, `loc` properties holding objects with
// `start` and `end` properties in `{line, column}` form (with // `start` and `end` properties in `{line, column}` form (with
@@ -2949,6 +2950,9 @@ module.exports = {
if (options.allowReserved == null) if (options.allowReserved == null)
{ options.allowReserved = options.ecmaVersion < 5; } { options.allowReserved = options.ecmaVersion < 5; }
if (opts.allowHashBang == null)
{ options.allowHashBang = options.ecmaVersion >= 14; }
if (isArray(options.onToken)) { if (isArray(options.onToken)) {
var tokens = options.onToken; var tokens = options.onToken;
options.onToken = function (token) { return tokens.push(token); }; options.onToken = function (token) { return tokens.push(token); };
@@ -3279,7 +3283,7 @@ module.exports = {
if (refDestructuringErrors.trailingComma > -1) if (refDestructuringErrors.trailingComma > -1)
{ this.raiseRecoverable(refDestructuringErrors.trailingComma, "Comma is not permitted after the rest element"); } { this.raiseRecoverable(refDestructuringErrors.trailingComma, "Comma is not permitted after the rest element"); }
var parens = isAssign ? refDestructuringErrors.parenthesizedAssign : refDestructuringErrors.parenthesizedBind; var parens = isAssign ? refDestructuringErrors.parenthesizedAssign : refDestructuringErrors.parenthesizedBind;
if (parens > -1) { this.raiseRecoverable(parens, "Parenthesized pattern"); } if (parens > -1) { this.raiseRecoverable(parens, isAssign ? "Assigning to rvalue" : "Parenthesized pattern"); }
}; };
pp$9.checkExpressionErrors = function(refDestructuringErrors, andThrow) { pp$9.checkExpressionErrors = function(refDestructuringErrors, andThrow) {
@@ -4375,6 +4379,7 @@ module.exports = {
}; };
pp$8.isDirectiveCandidate = function(statement) { pp$8.isDirectiveCandidate = function(statement) {
return ( return (
this.options.ecmaVersion >= 5 &&
statement.type === "ExpressionStatement" && statement.type === "ExpressionStatement" &&
statement.expression.type === "Literal" && statement.expression.type === "Literal" &&
typeof statement.expression.value === "string" && typeof statement.expression.value === "string" &&
@@ -4785,7 +4790,8 @@ module.exports = {
{ this.exprAllowed = type.beforeExpr; } { this.exprAllowed = type.beforeExpr; }
}; };
// Used to handle egde case when token context could not be inferred correctly in tokenize phase // Used to handle egde cases when token context could not be inferred correctly during tokenization phase
pp$6.overrideContext = function(tokenCtx) { pp$6.overrideContext = function(tokenCtx) {
if (this.curContext() !== tokenCtx) { if (this.curContext() !== tokenCtx) {
this.context[this.context.length - 1] = tokenCtx; this.context[this.context.length - 1] = tokenCtx;
@@ -5601,15 +5607,6 @@ module.exports = {
} }
return this.finishNode(prop, "RestElement") return this.finishNode(prop, "RestElement")
} }
// To disallow parenthesized identifier via `this.toAssignable()`.
if (this.type === types$1.parenL && refDestructuringErrors) {
if (refDestructuringErrors.parenthesizedAssign < 0) {
refDestructuringErrors.parenthesizedAssign = this.start;
}
if (refDestructuringErrors.parenthesizedBind < 0) {
refDestructuringErrors.parenthesizedBind = this.start;
}
}
// Parse argument. // Parse argument.
prop.argument = this.parseMaybeAssign(false, refDestructuringErrors); prop.argument = this.parseMaybeAssign(false, refDestructuringErrors);
// To disallow trailing comma via `this.toAssignable()`. // To disallow trailing comma via `this.toAssignable()`.
@@ -8039,7 +8036,7 @@ module.exports = {
// Acorn is a tiny, fast JavaScript parser written in JavaScript. // Acorn is a tiny, fast JavaScript parser written in JavaScript.
var version = "8.7.1"; var version = "8.8.0";
Parser.acorn = { Parser.acorn = {
Parser: Parser, Parser: Parser,
@@ -15189,21 +15186,17 @@ async function enablePagesSite({ repositoryNwo, githubToken }) {
} }
async function getPagesSite({ repositoryNwo, githubToken }) { async function getPagesSite({ repositoryNwo, githubToken }) {
try { const pagesEndpoint = `${getApiBaseUrl()}/repos/${repositoryNwo}/pages`
const pagesEndpoint = `${getApiBaseUrl()}/repos/${repositoryNwo}/pages`
const response = await axios.get(pagesEndpoint, { const response = await axios.get(pagesEndpoint, {
headers: { headers: {
Accept: 'application/vnd.github.v3+json', Accept: 'application/vnd.github.v3+json',
Authorization: `Bearer ${githubToken}` Authorization: `Bearer ${githubToken}`
} }
}) })
const pageObject = response.data const pageObject = response.data
return pageObject return pageObject
} catch (error) {
throw error
}
} }
async function findOrCreatePagesSite({ repositoryNwo, githubToken, enablement = true }) { async function findOrCreatePagesSite({ repositoryNwo, githubToken, enablement = true }) {
@@ -15443,6 +15436,7 @@ class ConfigParser {
var depth = 0 var depth = 0
const properties = propertyName.split('.') const properties = propertyName.split('.')
var lastNode = configurationObject var lastNode = configurationObject
// eslint-disable-next-line no-constant-condition
while (true) { while (true) {
// Find the node for the current property // Find the node for the current property
var propertyNode = this.findProperty(lastNode, properties[depth]) var propertyNode = this.findProperty(lastNode, properties[depth])
@@ -15680,7 +15674,7 @@ function setPagesConfig({ staticSiteGenerator, generatorConfigFile, siteUrl }) {
} catch (error) { } catch (error) {
// Logging // Logging
core.warning( core.warning(
`We were unable to determine how to inject the site metadata into your config. Generated URLs may be incorrect. The base URL for this site should be ${path}. Please ensure your framework is configured to generate relative links appropriately.`, `We were unable to determine how to inject the site metadata into your config. Generated URLs may be incorrect. The base URL for this site should be ${siteUrl}. Please ensure your framework is configured to generate relative links appropriately.`,
error error
) )
} }
@@ -16509,14 +16503,15 @@ TokenTranslator.prototype = {
const SUPPORTED_VERSIONS = [ const SUPPORTED_VERSIONS = [
3, 3,
5, 5,
6, 6, // 2015
7, 7, // 2016
8, 8, // 2017
9, 9, // 2018
10, 10, // 2019
11, 11, // 2020
12, 12, // 2021
13 13, // 2022
14 // 2023
]; ];
/** /**
@@ -16634,12 +16629,23 @@ const ESPRIMA_FINISH_NODE = Symbol("espree's esprimaFinishNode");
* @param {int} end The index at which the comment ends. * @param {int} end The index at which the comment ends.
* @param {Location} startLoc The location at which the comment starts. * @param {Location} startLoc The location at which the comment starts.
* @param {Location} endLoc The location at which the comment ends. * @param {Location} endLoc The location at which the comment ends.
* @param {string} code The source code being parsed.
* @returns {Object} The comment object. * @returns {Object} The comment object.
* @private * @private
*/ */
function convertAcornCommentToEsprimaComment(block, text, start, end, startLoc, endLoc) { function convertAcornCommentToEsprimaComment(block, text, start, end, startLoc, endLoc, code) {
let type;
if (block) {
type = "Block";
} else if (code.slice(start, start + 2) === "#!") {
type = "Hashbang";
} else {
type = "Line";
}
const comment = { const comment = {
type: block ? "Block" : "Line", type,
value: text value: text
}; };
@@ -16684,6 +16690,25 @@ var espree = () => Parser => {
? new TokenTranslator(tokTypes, code) ? new TokenTranslator(tokTypes, code)
: null; : null;
/*
* Data that is unique to Espree and is not represented internally
* in Acorn.
*
* For ES2023 hashbangs, Espree will call `onComment()` during the
* constructor, so we must define state before having access to
* `this`.
*/
const state = {
originalSourceType: originalSourceType || options.sourceType,
tokens: tokenTranslator ? [] : null,
comments: options.comment === true ? [] : null,
impliedStrict: ecmaFeatures.impliedStrict === true && options.ecmaVersion >= 5,
ecmaVersion: options.ecmaVersion,
jsxAttrValueToken: false,
lastToken: null,
templateElements: []
};
// Initialize acorn parser. // Initialize acorn parser.
super({ super({
@@ -16702,38 +16727,28 @@ var espree = () => Parser => {
if (tokenTranslator) { if (tokenTranslator) {
// Use `tokens`, `ecmaVersion`, and `jsxAttrValueToken` in the state. // Use `tokens`, `ecmaVersion`, and `jsxAttrValueToken` in the state.
tokenTranslator.onToken(token, this[STATE]); tokenTranslator.onToken(token, state);
} }
if (token.type !== tokTypes.eof) { if (token.type !== tokTypes.eof) {
this[STATE].lastToken = token; state.lastToken = token;
} }
}, },
// Collect comments // Collect comments
onComment: (block, text, start, end, startLoc, endLoc) => { onComment: (block, text, start, end, startLoc, endLoc) => {
if (this[STATE].comments) { if (state.comments) {
const comment = convertAcornCommentToEsprimaComment(block, text, start, end, startLoc, endLoc); const comment = convertAcornCommentToEsprimaComment(block, text, start, end, startLoc, endLoc, code);
this[STATE].comments.push(comment); state.comments.push(comment);
} }
} }
}, code); }, code);
/* /*
* Data that is unique to Espree and is not represented internally in * We put all of this data into a symbol property as a way to avoid
* Acorn. We put all of this data into a symbol property as a way to * potential naming conflicts with future versions of Acorn.
* avoid potential naming conflicts with future versions of Acorn.
*/ */
this[STATE] = { this[STATE] = state;
originalSourceType: originalSourceType || options.sourceType,
tokens: tokenTranslator ? [] : null,
comments: options.comment === true ? [] : null,
impliedStrict: ecmaFeatures.impliedStrict === true && this.options.ecmaVersion >= 5,
ecmaVersion: this.options.ecmaVersion,
jsxAttrValueToken: false,
lastToken: null,
templateElements: []
};
} }
tokenize() { tokenize() {
@@ -16946,7 +16961,7 @@ var espree = () => Parser => {
}; };
}; };
const version$1 = "9.3.2"; const version$1 = "9.4.0";
/** /**
* @fileoverview Main Espree file that converts Acorn into Esprima output. * @fileoverview Main Espree file that converts Acorn into Esprima output.

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

3835
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -5,9 +5,12 @@
"description": "A GitHub Action to enable Pages and extract various metadata about a site. It can also be used to configure various static site generators we support as starter workflows.", "description": "A GitHub Action to enable Pages and extract various metadata about a site. It can also be used to configure various static site generators we support as starter workflows.",
"main": "./dist/index.js", "main": "./dist/index.js",
"scripts": { "scripts": {
"format": "prettier --write 'src/**/*.js'", "all": "npm run format && npm run lint && npm run prepare && npm run test",
"format:check": "prettier --check 'src/**/*.js'", "format": "prettier --write .",
"prepare": "npm run format && ncc build src/index.js -o dist --source-map --license licenses.txt", "format:check": "prettier --check .",
"lint": "DEBUG=eslint:cli-engine eslint --fix .",
"lint:check": "DEBUG=eslint:cli-engine eslint .",
"prepare": "ncc build src/index.js -o dist --source-map --license licenses.txt",
"test": "jest" "test": "jest"
}, },
"repository": { "repository": {
@@ -27,6 +30,9 @@
}, },
"devDependencies": { "devDependencies": {
"@vercel/ncc": "^0.34.0", "@vercel/ncc": "^0.34.0",
"eslint": "^8.23.1",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-github": "^4.3.7",
"jest": "^28.1.1", "jest": "^28.1.1",
"prettier": "^2.7.1" "prettier": "^2.7.1"
} }

View File

@@ -33,21 +33,17 @@ async function enablePagesSite({ repositoryNwo, githubToken }) {
} }
async function getPagesSite({ repositoryNwo, githubToken }) { async function getPagesSite({ repositoryNwo, githubToken }) {
try { const pagesEndpoint = `${getApiBaseUrl()}/repos/${repositoryNwo}/pages`
const pagesEndpoint = `${getApiBaseUrl()}/repos/${repositoryNwo}/pages`
const response = await axios.get(pagesEndpoint, { const response = await axios.get(pagesEndpoint, {
headers: { headers: {
Accept: 'application/vnd.github.v3+json', Accept: 'application/vnd.github.v3+json',
Authorization: `Bearer ${githubToken}` Authorization: `Bearer ${githubToken}`
} }
}) })
const pageObject = response.data const pageObject = response.data
return pageObject return pageObject
} catch (error) {
throw error
}
} }
async function findOrCreatePagesSite({ repositoryNwo, githubToken, enablement = true }) { async function findOrCreatePagesSite({ repositoryNwo, githubToken, enablement = true }) {

View File

@@ -189,6 +189,7 @@ class ConfigParser {
var depth = 0 var depth = 0
const properties = propertyName.split('.') const properties = propertyName.split('.')
var lastNode = configurationObject var lastNode = configurationObject
// eslint-disable-next-line no-constant-condition
while (true) { while (true) {
// Find the node for the current property // Find the node for the current property
var propertyNode = this.findProperty(lastNode, properties[depth]) var propertyNode = this.findProperty(lastNode, properties[depth])

View File

@@ -1,7 +1,7 @@
/** @type {import('next').NextConfig} */ /** @type {import('next').NextConfig} */
const nextConfig = { const nextConfig = {
reactStrictMode: true, reactStrictMode: true,
swcMinify: true, swcMinify: true
} }
module.exports = nextConfig module.exports = nextConfig

View File

@@ -1,7 +1,7 @@
/** @type {import('next').NextConfig} */ /** @type {import('next').NextConfig} */
const nextConfig = { const nextConfig = {
reactStrictMode: true, reactStrictMode: true,
swcMinify: true, swcMinify: true
} }
export default nextConfig export default nextConfig

View File

@@ -1,15 +1,15 @@
const getAllDynamicRoute = async function() { const getAllDynamicRoute = async function () {
const routes = await (async () => { const routes = await (async () => {
return ['/posts/hello-world', '/posts/hello-again']; return ['/posts/hello-world', '/posts/hello-again']
})(); })()
return routes; return routes
}; }
module.exports = { module.exports = {
mode: 'universal', mode: 'universal',
generate: { generate: {
async routes () { async routes() {
return getAllDynamicRoute(); return getAllDynamicRoute()
} }
} }
}; }

View File

@@ -1,17 +1,17 @@
const getAllDynamicRoute = async function() { const getAllDynamicRoute = async function () {
const routes = await (async () => { const routes = await (async () => {
return ['/posts/hello-world', '/posts/hello-again']; return ['/posts/hello-world', '/posts/hello-again']
})(); })()
return routes; return routes
}; }
module.exports = { module.exports = {
target: 'static', target: 'static',
router: { base: '/docs/' }, router: { base: '/docs/' },
mode: 'universal', mode: 'universal',
generate: { generate: {
async routes () { async routes() {
return getAllDynamicRoute(); return getAllDynamicRoute()
} }
} }
}; }

View File

@@ -1,17 +1,17 @@
const getAllDynamicRoute = async function() { const getAllDynamicRoute = async function () {
const routes = await (async () => { const routes = await (async () => {
return ['/posts/hello-world', '/posts/hello-again']; return ['/posts/hello-world', '/posts/hello-again']
})(); })()
return routes; return routes
}; }
export default { export default {
target: 'static', target: 'static',
router: { base: '/docs/' }, router: { base: '/docs/' },
mode: 'universal', mode: 'universal',
generate: { generate: {
async routes () { async routes() {
return getAllDynamicRoute(); return getAllDynamicRoute()
} }
} }
}; }

View File

@@ -1,15 +1,15 @@
const getAllDynamicRoute = async function() { const getAllDynamicRoute = async function () {
const routes = await (async () => { const routes = await (async () => {
return ['/posts/hello-world', '/posts/hello-again']; return ['/posts/hello-world', '/posts/hello-again']
})(); })()
return routes; return routes
}; }
export default { export default {
mode: 'universal', mode: 'universal',
generate: { generate: {
async routes () { async routes() {
return getAllDynamicRoute(); return getAllDynamicRoute()
} }
} }
}; }

View File

@@ -14,9 +14,7 @@ module.exports = {
{ hid: 'description', name: 'description', content: '' }, { hid: 'description', name: 'description', content: '' },
{ name: 'format-detection', content: 'telephone=no' } { name: 'format-detection', content: 'telephone=no' }
], ],
link: [ link: [{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }]
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
]
}, },
// Global CSS: https://go.nuxtjs.dev/config-css // Global CSS: https://go.nuxtjs.dev/config-css
@@ -36,4 +34,4 @@ module.exports = {
// Build Configuration: https://go.nuxtjs.dev/config-build // Build Configuration: https://go.nuxtjs.dev/config-build
build: {} build: {}
} }

View File

@@ -16,9 +16,7 @@ module.exports = {
{ hid: 'description', name: 'description', content: '' }, { hid: 'description', name: 'description', content: '' },
{ name: 'format-detection', content: 'telephone=no' } { name: 'format-detection', content: 'telephone=no' }
], ],
link: [ link: [{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }]
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
]
}, },
// Global CSS: https://go.nuxtjs.dev/config-css // Global CSS: https://go.nuxtjs.dev/config-css
@@ -38,4 +36,4 @@ module.exports = {
// Build Configuration: https://go.nuxtjs.dev/config-build // Build Configuration: https://go.nuxtjs.dev/config-build
build: {} build: {}
} }

View File

@@ -16,9 +16,7 @@ export default {
{ hid: 'description', name: 'description', content: '' }, { hid: 'description', name: 'description', content: '' },
{ name: 'format-detection', content: 'telephone=no' } { name: 'format-detection', content: 'telephone=no' }
], ],
link: [ link: [{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }]
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
]
}, },
// Global CSS: https://go.nuxtjs.dev/config-css // Global CSS: https://go.nuxtjs.dev/config-css
@@ -38,4 +36,4 @@ export default {
// Build Configuration: https://go.nuxtjs.dev/config-build // Build Configuration: https://go.nuxtjs.dev/config-build
build: {} build: {}
} }

View File

@@ -14,9 +14,7 @@ export default {
{ hid: 'description', name: 'description', content: '' }, { hid: 'description', name: 'description', content: '' },
{ name: 'format-detection', content: 'telephone=no' } { name: 'format-detection', content: 'telephone=no' }
], ],
link: [ link: [{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }]
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
]
}, },
// Global CSS: https://go.nuxtjs.dev/config-css // Global CSS: https://go.nuxtjs.dev/config-css
@@ -36,4 +34,4 @@ export default {
// Build Configuration: https://go.nuxtjs.dev/config-build // Build Configuration: https://go.nuxtjs.dev/config-build
build: {} build: {}
} }

View File

@@ -76,7 +76,7 @@ function setPagesConfig({ staticSiteGenerator, generatorConfigFile, siteUrl }) {
} catch (error) { } catch (error) {
// Logging // Logging
core.warning( core.warning(
`We were unable to determine how to inject the site metadata into your config. Generated URLs may be incorrect. The base URL for this site should be ${path}. Please ensure your framework is configured to generate relative links appropriately.`, `We were unable to determine how to inject the site metadata into your config. Generated URLs may be incorrect. The base URL for this site should be ${siteUrl}. Please ensure your framework is configured to generate relative links appropriately.`,
error error
) )
} }