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

@bikeshaving/crank

Package Overview
Dependencies
Maintainers
1
Versions
44
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@bikeshaving/crank - npm Package Versions

2345

0.4.4

Diff

Changelog

Source

[0.4.4] - 2022-08-08

Fixed

  • Inlined event listener methods to avoid errors caused by bundling (#238).
brainkim
published 0.4.3 •

Changelog

Source

[0.4.3] - 2022-06-25

Fixed

  • Fix readonly DOM properties not being set correctly (#231).
brainkim
published 0.4.2 •

Changelog

Source

[0.4.2] - 2021-12-20

Fixed

  • Fix null/undefined in className property for HTML renderer.
brainkim
published 0.4.1 •

Changelog

Source

[0.4.1] - 2021-10-29

Added

  • createElement and Fragment have been added to default module exports, to work with more JSX tools (#219).

Fixed

  • The HTMLRenderer will now correctly render className props (#221).
  • Fixed a bug where <Raw /> elements with parsed string values would lose their contents when rerendered (#224).

Changed

  • As part of #224, the internal RendererImpl.parse() method can now take any ElementValue<TNode> instead of TNode.
  • The ./ export which was added in 0.4 was removed from package.json.
  • The main and module fields will now point to crank.js.
brainkim
published 0.4.0 •

Changelog

Source

[0.4.0] - 2021-10-08

Added

  • Special props crank-key, crank-ref, crank-static now have shorthand equivalents c-key, c-ref, and c-static to save on typing.
  • Crank is now published under the NPM package @b9g/crank, as well as the old @bikeshaving/crank. Again, this saves on typing.
  • The Context.prototype.flush() method has been added. It behaves similarly to Context.prototype.schedule(), with the exception that it runs after a component’s children is in the DOM. This is important for things like focusing after render. See #180 for motivation.
  • The c-skip (crank-skip) prop has been added as an alternative to <Copy /> elements. See #173 for motivation and src/__tests__/static.tsx for examples.

Changed

  • I gave up and we now use .cjs files instead of /cjs directories for commonjs fallbacks.
  • innerHTML now checks against the old prop value rather than reading from the DOM.
  • Properties and styles which are missing from DOM element props will now be removed. Crank 0.3 tried to implement uncontrolled properties by saying missing props were uncontrolled. For instance, <div class="class" /> rerendered as <div /> would preserve the class property even though it was removed. Starting in 0.4, missing props and styles will be removed from DOM elements between renders.
  • Crank will now log a console error when undefined is yielded or returned from a component. To squash these warnings, yield or return null instead.
  • The default type for TagProps is now Record<string, unknown> as opposed to unknown.
  • Crank will no longer attempt to reuse or modify elements. Motivated by #198.
  • Internal context properties have been hidden using a symbol.
  • The internal Renderer API has been overhauled yet again.
    • All internal methods which are implemented by the various renderers (create(), patch(), arrange()) have been removed from the base renderer class. Instead, you will now have to pass in these methods via a call to super() in the constructor. See src/dom.ts or src/html.ts for examples.
    • The complete() method has been renamed to flush().
    • patch() now runs per prop as opposed to passing all props.
    • patch() now runs in a post-order call of the tree (yet again).
    • The signatures of all of the methods have been changed, mainly to avoid passing elements into the renderer, and allow for previous values to be inspected and used.

Fixed

  • Fixed some edge cases where event bubbling would result in `"Generator is already executing.
  • Assigning to boolean properties with strings like spellcheck="true" will now work as expected. See #175 for motivation. "` errors.
brainkim
published 0.4.0-beta.3 •

brainkim
published 0.4.0-beta.2 •

brainkim
published 0.4.0-beta.1 •

brainkim
published 0.3.11 •

Changelog

Source

[0.3.11] - 2021-05-11

Fixed

  • Crank will now always create new elements for internal nodes to prevent subtle aliasing bugs (#198).
  • Fixed an edge case where a scheduled refresh failed to update the component when the produced child was a component (#199).
  • Optimized multiple components scheduling a refresh synchronously (#155).
brainkim
published 0.3.10 •

Changelog

Source

[0.3.10] - 2021-04-30

Fixed

  • Fixed Copy elements of async generator components causing parents to hang (#197).
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