Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(meta,manifest): Set default undefined for description and author #483

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/content/en/manifest.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ pwa: {
| --------------------------------- | --------------- | ------------------------------------------------------------ | --------------------------------------------------------------- |
| `name` <sup>\*1</sup> | `String` | `package.json`'s name property | [maximum of 45 characters] |
| `short_name` <sup>\*1</sup> | `String` | `package.json`'s name property | [maximum of 12 characters] |
| `description` <sup>\*2</sup> | `String` | `package.json`'s description property | |
| `description` <sup>\*2</sup> | `String` | `undefined` | |
| `icons` <sup>\*1</sup> | `Array<Object>` | `[]` | (See the [icon module]) |
| `start_url` <sup>\*1</sup> | `String` | `routerBase + '?standalone=true'` | It has to be relative to where the manifest is placed |
| `display` <sup>\*1</sup> | `String` | `'standalone'` | |
Expand Down
4 changes: 2 additions & 2 deletions docs/content/en/meta.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,11 @@ These articles will help you decide an appropriate value:
- Meta: `title`

### `author`
- Default: *npm_package_author_name*
- Default: `undefined`
- Meta: `author`

### `description`
- Default: *npm_package_description*
- Default: `undefined`
- Meta: `description`

### `theme_color`
Expand Down
2 changes: 1 addition & 1 deletion src/manifest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export function manifest (nuxt, pwa: PWAContext) {
const defaults: ManifestOptions = {
name: process.env.npm_package_name,
short_name: process.env.npm_package_name,
description: process.env.npm_package_description,
description: undefined,
publicPath,
icons: [],
start_url: routerBase + '?standalone=true',
Expand Down
4 changes: 2 additions & 2 deletions src/meta.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ export function meta (nuxt, pwa: PWAContext, moduleContainer) {
// Defaults
const defaults: MetaOptions = {
name: process.env.npm_package_name,
author: process.env.npm_package_author_name,
description: process.env.npm_package_description,
author: undefined,
description: undefined,
charset: 'utf-8',
viewport: undefined,
mobileApp: true,
Expand Down
2 changes: 1 addition & 1 deletion types/manifest.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export interface ManifestOptions {
*/
short_name: string,
/**
* Default: _npm_package_description_
* Default: undefined
*/
description: string,
/**
Expand Down
4 changes: 2 additions & 2 deletions types/meta.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,13 @@ export interface MetaOptions extends Partial<ManifestOptions> {
*/
title?: string,
/**
* Default: _npm_package_author_name_
* Default: undefined
*
* Meta: `author`
*/
author: string,
/**
* Default: _npm_package_description_
* Default: undefined
*
* Meta: `description`
*/
Expand Down