Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@b9g/crank

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@b9g/crank - npm Package Compare versions

Comparing version 0.5.1 to 0.5.2

14

crank.d.ts

@@ -380,3 +380,3 @@ /**

declare const _ContextImpl: unique symbol;
type ComponentProps<T> = T extends (props: infer U) => any ? U : T;
type ComponentProps<T> = T extends () => any ? {} : T extends (props: infer U) => any ? U : T;
/**

@@ -388,4 +388,4 @@ * A class which is instantiated and passed to every component as its this

*
* @template [TProps=*] - The expected shape of the props passed to the
* component. Used to strongly type the Context iterator methods.
* @template [T=*] - The expected shape of the props passed to the component,
* or a component function. Used to strongly type the Context iterator methods.
* @template [TResult=*] - The readable element value type. It is used in

@@ -395,3 +395,3 @@ * places such as the return value of refresh and the argument passed to

*/
export declare class Context<TProps = any, TResult = any> implements EventTarget {
export declare class Context<T = any, TResult = any> implements EventTarget {
/**

@@ -409,3 +409,3 @@ * @internal

*/
get props(): ComponentProps<TProps>;
get props(): ComponentProps<T>;
/**

@@ -419,4 +419,4 @@ * The current value of the associated element.

get value(): TResult;
[Symbol.iterator](): Generator<ComponentProps<TProps>>;
[Symbol.asyncIterator](): AsyncGenerator<ComponentProps<TProps>>;
[Symbol.iterator](): Generator<ComponentProps<T>>;
[Symbol.asyncIterator](): AsyncGenerator<ComponentProps<T>>;
/**

@@ -423,0 +423,0 @@ * Re-executes a component.

@@ -36,3 +36,4 @@ /// <reference types="dom.d.ts" />

tag.toUpperCase() !== node.tagName) {
console.error(`Expected <${tag}> while hydrating but found:`, node);
// TODO: consider pros and cons of hydration warnings
//console.error(`Expected <${tag}> while hydrating but found:`, node);
return undefined;

@@ -226,5 +227,3 @@ }

let value = hydrationData.children.shift();
if (typeof value !== "string" || !value.startsWith(text)) {
console.error(`Expected "${text}" while hydrating but found:`, value);
}
if (typeof value !== "string" || !value.startsWith(text)) ;
else if (text.length < value.length) {

@@ -231,0 +230,0 @@ value = value.slice(text.length);

{
"name": "@b9g/crank",
"version": "0.5.1",
"version": "0.5.2",
"description": "Write JSX-driven components with functions, promises and generators.",

@@ -44,2 +44,10 @@ "homepage": "https://crank.js.org",

},
"./jsx-dev-runtime": {
"import": "./jsx-runtime.js",
"require": "./jsx-runtime.cjs"
},
"./jsx-dev-runtime.js": {
"import": "./jsx-runtime.js",
"require": "./jsx-runtime.cjs"
},
"./jsx-runtime": {

@@ -97,3 +105,3 @@ "import": "./jsx-runtime.js",

"ts-node": "^10.9.1",
"typescript": "^4.9.4",
"typescript": "^4.9.5",
"uvu": "^0.5.6"

@@ -100,0 +108,0 @@ },

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

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