Merge pull request #701 from liyasthomas/refactor/nuxt

📦 Updating packages
This commit is contained in:
Liyas Thomas
2020-03-24 08:00:40 +05:30
committed by GitHub
3 changed files with 29 additions and 32 deletions

View File

@@ -1,6 +1,6 @@
// Some helpful application constants.
// TODO: Use these when rendering the pages (rather than just for head/meta tags...)
export const meta = {
export const options = {
name: "Postwoman",
shortDescription: "A free, fast and beautiful API request builder",
description:
@@ -39,7 +39,7 @@ export default {
},
},
head: {
title: `${meta.name} \u2022 ${meta.shortDescription}`,
title: `${options.name} \u2022 ${options.shortDescription}`,
meta: [
{
charset: "utf-8",
@@ -52,7 +52,7 @@ export default {
{
hid: "description",
name: "description",
content: meta.description || "",
content: options.description || "",
},
{
name: "keywords",
@@ -65,11 +65,11 @@ export default {
},
{
itemprop: "name",
content: `${meta.name} \u2022 ${meta.shortDescription}`,
content: `${options.name} \u2022 ${options.shortDescription}`,
},
{
itemprop: "description",
content: meta.description,
content: options.description,
},
{
itemprop: "image",
@@ -78,7 +78,7 @@ export default {
// Add to homescreen for Chrome on Android. Fallback for PWA (handled by nuxt)
{
name: "application-name",
content: meta.name,
content: options.name,
},
// Add to homescreen for Safari on iOS
{
@@ -91,7 +91,7 @@ export default {
},
{
name: "apple-mobile-web-app-title",
content: meta.name,
content: options.name,
},
// Windows phone tile icon
{
@@ -109,7 +109,7 @@ export default {
// OpenGraph
{
property: "og:site_name",
content: meta.name,
content: options.name,
},
{
property: "og:url",
@@ -121,11 +121,11 @@ export default {
},
{
property: "og:title",
content: `${meta.name} \u2022 ${meta.shortDescription}`,
content: `${options.name} \u2022 ${options.shortDescription}`,
},
{
property: "og:description",
content: meta.description,
content: options.description,
},
{
property: "og:image",
@@ -150,11 +150,11 @@ export default {
},
{
name: "twitter:title",
content: `${meta.name} \u2022 ${meta.shortDescription}`,
content: `${options.name} \u2022 ${options.shortDescription}`,
},
{
name: "twitter:description",
content: meta.description,
content: options.description,
},
{
name: "twitter:image",
@@ -227,7 +227,7 @@ export default {
/*
** Nuxt.js dev-modules
*/
buildModules: [],
buildModules: ["@nuxtjs/gtm"],
/*
** Nuxt.js modules
*/
@@ -238,33 +238,25 @@ export default {
["@nuxtjs/toast"],
["@nuxtjs/google-analytics"],
["@nuxtjs/sitemap"],
[
"@nuxtjs/google-tag-manager",
{
id: process.env.GTM_ID || "GTM-MXWD8NQ",
},
],
["@nuxtjs/robots"],
["nuxt-i18n"],
],
pwa: {
manifest: {
name: meta.name,
short_name: meta.name,
name: options.name,
short_name: options.name,
display: "standalone",
theme_color: "#202124",
background_color: "#202124",
start_url: `${routerBase.router.base}`,
},
meta: {
description: meta.shortDescription,
description: options.shortDescription,
theme_color: "#202124",
},
icons: (sizes => {
icons: ((sizes) => {
let icons = []
for (let size of sizes) {
icons.push({
@@ -285,6 +277,9 @@ export default {
googleAnalytics: {
id: process.env.GA_ID || "UA-61422507-2",
},
gtm: {
id: process.env.GTM_ID || "GTM-MXWD8NQ",
},
sitemap: {
hostname: "https://postwoman.io",
},

12
package-lock.json generated
View File

@@ -3162,14 +3162,15 @@
"version": "2.2.3",
"resolved": "https://registry.npmjs.org/@nuxtjs/google-analytics/-/google-analytics-2.2.3.tgz",
"integrity": "sha512-dPwgsRNECtZqHdmnbJRFy3T4DDVakrpeN7vM1DwAIV1FXYlIBMKvdi8nt1v8TPU4IZdaoXrQodfeNMCooPo/7g==",
"dev": true,
"requires": {
"vue-analytics": "^5.22.1"
}
},
"@nuxtjs/google-tag-manager": {
"version": "2.3.2",
"resolved": "https://registry.npmjs.org/@nuxtjs/google-tag-manager/-/google-tag-manager-2.3.2.tgz",
"integrity": "sha512-i2rpIy6ekH1Wv2jAoEZ9q5e16jQM/OG4xgC9mi0yVFxnrXv2N93+ca04wWMESP6tekuy7FxpDdoN2vlrBLTqrw=="
"@nuxtjs/gtm": {
"version": "2.2.3",
"resolved": "https://registry.npmjs.org/@nuxtjs/gtm/-/gtm-2.2.3.tgz",
"integrity": "sha512-YRvxCo2rpe61kR49LmepK0lCjrrb3hvb89X7/AO5IFPzPU6hxUDpi4V3rnahUTwHcDdYknVqtjAn8ZFMp+HE2Q=="
},
"@nuxtjs/proxy": {
"version": "1.3.3",
@@ -14993,7 +14994,8 @@
"vue-analytics": {
"version": "5.22.1",
"resolved": "https://registry.npmjs.org/vue-analytics/-/vue-analytics-5.22.1.tgz",
"integrity": "sha512-HPKQMN7gfcUqS5SxoO0VxqLRRSPkG1H1FqglsHccz6BatBatNtm/Vyy8brApktZxNCfnAkrSVDpxg3/FNDeOgQ=="
"integrity": "sha512-HPKQMN7gfcUqS5SxoO0VxqLRRSPkG1H1FqglsHccz6BatBatNtm/Vyy8brApktZxNCfnAkrSVDpxg3/FNDeOgQ==",
"dev": true
},
"vue-client-only": {
"version": "2.0.0",

View File

@@ -31,8 +31,7 @@
},
"dependencies": {
"@nuxtjs/axios": "^5.9.5",
"@nuxtjs/google-analytics": "^2.2.3",
"@nuxtjs/google-tag-manager": "^2.3.2",
"@nuxtjs/gtm": "^2.2.3",
"@nuxtjs/pwa": "^3.0.0-beta.20",
"@nuxtjs/robots": "^2.4.2",
"@nuxtjs/sitemap": "^2.0.1",
@@ -53,6 +52,7 @@
"yargs-parser": "^18.1.1"
},
"devDependencies": {
"@nuxtjs/google-analytics": "^2.2.3",
"cypress": "^4.2.0",
"husky": "^4.2.3",
"lint-staged": "^10.0.8",