Socket
Socket
Sign inDemoInstall

@zhead/schema

Package Overview
Dependencies
Maintainers
1
Versions
61
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@zhead/schema - npm Package Compare versions

Comparing version 0.7.4 to 0.8.0

77

dist/index.d.ts

@@ -136,2 +136,20 @@ interface BodyAttributes {

declare type Booleanable = boolean | 'false' | 'true' | '';
declare type Stringable = string | Booleanable | number;
interface DataKeys {
[key: `data-${string}`]: Stringable;
}
declare type Default<T extends undefined | Record<string, any>, D = {}> = [T] extends [undefined] ? D : T;
declare type Merge<T extends undefined | Record<string, any>, D = {}> = [T] extends [undefined] ? D : D & T;
interface MergeHead {
base?: Record<string, any>;
link?: Record<string, any>;
meta?: Record<string, any>;
style?: Record<string, any>;
script?: Record<string, any>;
noscript?: Record<string, any>;
htmlAttrs?: Record<string, any>;
bodyAttrs?: Record<string, any>;
}
interface MetaFlat {

@@ -265,3 +283,3 @@ /**

*/
all: boolean;
all: Booleanable;
/**

@@ -271,3 +289,3 @@ * Do not show this page, media, or resource in search results.

*/
noindex: boolean;
noindex: Booleanable;
/**

@@ -277,7 +295,7 @@ * Do not follow the links on this page.

*/
nofollow: boolean;
nofollow: Booleanable;
/**
* Equivalent to noindex, nofollow.
*/
none: boolean;
none: Booleanable;
/**

@@ -288,3 +306,3 @@ * Do not show a cached link in search results.

*/
noarchive: boolean;
noarchive: Booleanable;
/**

@@ -295,3 +313,3 @@ * Do not show a sitelinks search box in the search results for this page.

*/
nositelinkssearchbox: boolean;
nositelinkssearchbox: Booleanable;
/**

@@ -302,3 +320,3 @@ *

*/
nosnippet: boolean;
nosnippet: Booleanable;
/**

@@ -310,3 +328,3 @@ * Google is allowed to index the content of a page if it's embedded in another

*/
indexifembedded: boolean;
indexifembedded: Booleanable;
/**

@@ -327,3 +345,3 @@ * Use a maximum of [number] characters as a textual snippet for this search result.

*/
notranslate: boolean;
notranslate: Booleanable;
/**

@@ -336,3 +354,3 @@ * Do not show this page in search results after the specified date/time.

*/
noimageindex: boolean;
noimageindex: Booleanable;
}>;

@@ -776,3 +794,3 @@ google:

*/
async?: boolean;
async?: Booleanable;
/**

@@ -792,3 +810,3 @@ * Normal script elements pass minimal information to the window.onerror

*/
defer?: boolean;
defer?: Booleanable;
/**

@@ -814,3 +832,3 @@ * Provides a hint of the relative priority to use when fetching an external script.

*/
nomodule?: boolean;
nomodule?: Booleanable;
/**

@@ -889,19 +907,2 @@ * A cryptographic nonce (number used once) to allow scripts in a script-src Content-Security-Policy.

declare type Stringable = string | boolean | number;
interface UnsafeKeys {
[key: string]: Stringable;
}
declare type Default<T extends undefined | Record<string, any>, D = {}> = [T] extends [undefined] ? D : T;
declare type Merge<T extends undefined | Record<string, any>, D = {}> = [T] extends [undefined] ? D : D & T;
interface MergeHead {
base?: Record<string, any>;
link?: Record<string, any>;
meta?: Record<string, any>;
style?: Record<string, any>;
script?: Record<string, any>;
noscript?: Record<string, any>;
htmlAttrs?: Record<string, any>;
bodyAttrs?: Record<string, any>;
}
interface Head<E extends MergeHead = MergeHead> {

@@ -933,3 +934,3 @@ /**

*/
link?: (Link & UnsafeKeys & Default<E['link']>)[];
link?: (Link & DataKeys & Default<E['link']>)[];
/**

@@ -940,3 +941,3 @@ * The <meta> element represents metadata that cannot be expressed in other HTML elements, like <link> or <script>.

*/
meta?: (Meta & UnsafeKeys & Default<E['meta']>)[];
meta?: (Meta & DataKeys & Default<E['meta']>)[];
/**

@@ -948,3 +949,3 @@ * The <style> HTML element contains style information for a document, or part of a document.

*/
style?: (Style & UnsafeKeys & Default<E['style']>)[];
style?: (Style & DataKeys & Default<E['style']>)[];
/**

@@ -955,3 +956,3 @@ * The <script> HTML element is used to embed executable code or data; this is typically used to embed or refer to JavaScript code.

*/
script?: (Script & UnsafeKeys & Default<E['script']>)[];
script?: (Script & DataKeys & Default<E['script']>)[];
/**

@@ -963,3 +964,3 @@ * The <noscript> HTML element defines a section of HTML to be inserted if a script type on the page is unsupported

*/
noscript?: (Noscript & UnsafeKeys & Default<E['noscript']>)[];
noscript?: (Noscript & DataKeys & Default<E['noscript']>)[];
/**

@@ -970,3 +971,3 @@ * Attributes for the <html> HTML element.

*/
htmlAttrs?: (HtmlAttributes & UnsafeKeys & Default<E['htmlAttrs']>);
htmlAttrs?: (HtmlAttributes & DataKeys & Default<E['htmlAttrs']>);
/**

@@ -977,5 +978,5 @@ * Attributes for the <body> HTML element.

*/
bodyAttrs?: (BodyAttributes & UnsafeKeys & Default<E['bodyAttrs']>);
bodyAttrs?: (BodyAttributes & DataKeys & Default<E['bodyAttrs']>);
}
export { Base, BodyAttributes, Default, Head, HtmlAttributes, Link, LinkRelTypes, Merge, MergeHead, Meta, MetaFlat, MetaFlatInput, Noscript, Script, Stringable, Style, StyleEntries, UnsafeKeys };
export { Base, BodyAttributes, Booleanable, DataKeys, Default, Head, HtmlAttributes, Link, LinkRelTypes, Merge, MergeHead, Meta, MetaFlat, MetaFlatInput, Noscript, Script, Stringable, Style, StyleEntries };
{
"name": "@zhead/schema",
"version": "0.7.4",
"version": "0.8.0",
"packageManager": "pnpm@7.8.0",

@@ -5,0 +5,0 @@ "author": "Harlan Wilton <harlan@harlanzw.com>",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc