Socket
Socket
Sign inDemoInstall

lit-html

Package Overview
Dependencies
Maintainers
11
Versions
102
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lit-html - npm Package Compare versions

Comparing version 0.11.0-dev.3 to 0.11.0

1

lib/directive.d.ts

@@ -17,5 +17,4 @@ /**

(part: P): void;
__litDirective?: true;
}
export declare const directive: <P = Part>(f: Directive<P>) => Directive<P>;
export declare const isDirective: (o: any) => boolean;

5

lib/directive.js

@@ -14,7 +14,8 @@ /**

*/
const directives = new WeakMap();
export const directive = (f) => {
f.__litDirective = true;
directives.set(f, true);
return f;
};
export const isDirective = (o) => typeof o === 'function' && o.__litDirective === true;
export const isDirective = (o) => directives.has(o);
//# sourceMappingURL=directive.js.map
{
"name": "lit-html",
"version": "0.11.0-dev.3",
"version": "0.11.0",
"description": "HTML template literals in JavaScript",

@@ -5,0 +5,0 @@ "license": "BSD-3-Clause",

@@ -17,13 +17,13 @@ /**

const directives = new WeakMap<any, Boolean>();
export interface Directive<P = Part> {
(part: P): void;
__litDirective?: true;
}
export const directive = <P = Part>(f: Directive<P>): Directive<P> => {
f.__litDirective = true;
directives.set(f, true);
return f;
};
export const isDirective = (o: any) =>
typeof o === 'function' && o.__litDirective === true;
export const isDirective = (o: any) => directives.has(o);

Sorry, the diff of this file is not supported yet

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