mojave

A library of commonly used JavaScript tools and helpers by Becklyn

BSD-3-CLAUSE License

Downloads
405
Stars
5
Committers
9

Bot releases are visible (Hide)

mojave -

Published by apfelbox almost 5 years ago

🎁 New Features

  • Added storeInLocalStorage() and fetchFromLocalStorage().

✨ Improvements

  • Use better default types + simplify implementation in json

Commits

  • Add more storage functions + use better default types in json (#245) bb01411
  • Fix missing return 7dd4472
  • Added storeInLocalStorage() and fetchFromLocalStorage() 268f198
  • Use better default types + simplify implementation in json dbc6e42
  • Use proper variable c35fcca

https://github.com/Becklyn/mojave/compare/5.5.4...5.6.0

mojave -

Published by apfelbox almost 5 years ago

✨ Improvements

  • classes() is now variadic and can also take string arguments. Also any truthy/falsy values are now supported in objects.
  • Allow passing null as element to parseElementAsJson()

Commits

  • Merge pull request #244 from Becklyn/classes-variadic 1376742
  • Allow passing null as element to parseElementAsJson() 2c12c80
  • Simplify implementation of classes() + make variadic 2b707ef

https://github.com/Becklyn/mojave/compare/5.5.3...5.5.4

mojave -

Published by apfelbox almost 5 years ago

✨ Improvements

  • popup-interaction::initDismissableContainer() now returns the close function. This way you can wire up your own close buttons, so
    that they are handled correctly.
  • popup-interaction::initDismissableContainer() can now handle multiple opener triggers.

Commits

  • Return the close function in initDismissableContainer (#243) 8f53e0e
  • Return the close function in initDismissableContainer 1afdf37
  • Add changelog entry f016348

https://github.com/Becklyn/mojave/compare/5.5.2...5.5.3

mojave -

Published by apfelbox almost 5 years ago

Fix apparently broken 5.5.1 build.

Also:

πŸ› οΈ Internal

  • Improve variable name

Commits

  • Improve variable name a0504bd

https://github.com/Becklyn/mojave/compare/5.5.1...5.5.2

mojave -

Published by apfelbox almost 5 years ago

πŸ› Bug Fixes

  • ts-toolbelt is a required dependency 7e7e48c

Commits

https://github.com/Becklyn/mojave/compare/5.5.0...5.5.1

mojave -

Published by apfelbox almost 5 years ago

(parallel release to 4.6.0)

🎁 New Features

  • Added more date formatter functions: formatDateTime() and formatDateTime().
  • Added a localized DateFormatter.

Commits

  • Add changelog for 5.5 72ebed2
  • Merge all v4 in v5 (#242) 8c9945a

https://github.com/Becklyn/mojave/compare/5.4.0...5.5.0

mojave -

Published by apfelbox almost 5 years ago

🎁 New Features

  • Added popup-interaction::initDismissableContainer() and popup-interaction::registerBodyClickHandler().

Commits

  • Add popup-interaction functions (#241) afca9fd
  • Add popup-interaction functions 32b5213

https://github.com/Becklyn/mojave/compare/5.3.0...5.4.0

mojave -

Published by apfelbox about 5 years ago

🎁 New Features

  • Added first Preact hook: useMediaQueryMatcher(mediaQueryMatcher).

πŸ› Bug Fixes

  • Add missing export for type MediaQueryMatcher.

Commits

  • Add useMediaQueryMatcher() preact hook (#240) bbf4745
  • Capitalize Preact since its a name 3ffda6f
  • Add useMediaQueryMatcher() preact hook c9c66a8
  • Add missing export for type MediaQueryMatcher (#239) 98f8c76
  • Add missing export for type MediaQueryMatcher 6760847
  • Fix typo in changelog 3758d66

https://github.com/Becklyn/mojave/compare/5.2.0...5.3.0

mojave -

Published by apfelbox about 5 years ago

🎁 New Features

  • Added dom/wire/wireSourceTargetLists()
  • Added mediaQueryMatcher() as a for attaching event listeners to window.matchMedia() without checking for the existence of addListener() or addEventListener() yourself.
  • Added storage/local-storage::persistedToggle

πŸ› οΈ Internal

  • Update ts-toolbelt to v4

Commits

  • Add persisted toggle helper (#232) c6e9b9b
  • Merge pull request #231 from Becklyn/renovate/ts-toolbelt-4.x fbab3da
  • Add persisted toggle helper ff59fe6
  • add media query listener (#235) d89b18a
  • Refactor implementation to use a more generic approach 64f8df0
  • save the realMatchMedia globally in tests 3356d3e
  • add media query listener 587fdbe
  • Add wireSourceTargetLists() (#238) 1c17343
  • Add wireSourceTargetLists a0ef236
  • Update dependency ts-toolbelt to v4 d6e0ea3

https://github.com/Becklyn/mojave/compare/5.1.1...5.2.0

mojave -

Published by apfelbox about 5 years ago

πŸ› Bug Fixes

  • If params are set in mountJsx, they only need to be a partial set of the props of the component now (as the rest can come from the mounted JSON container).

Commits

  • Allow partial JSX params (#237) a4c2362
  • Allow partial JSX params 9f74a80

https://github.com/Becklyn/mojave/compare/5.1.0...5.1.1

mojave -

Published by apfelbox about 5 years ago

🎁 New Features

  • Added onOff for easy event use in (preact) hooks.

Commits

  • Merge pull request #236 from Becklyn/on-off a882375
  • Add onOff 16db517

https://github.com/Becklyn/mojave/compare/5.0.0...5.1.0

mojave -

Published by keichinger about 5 years ago

πŸ’₯ Breaking Changes

  • Split doMount into specialized methods. This refactoring allows us to type inference parameters that your function or component requires:
    • mount for functions
    • mountClass for class components
    • mountJsx for Preact components

🎁 New Features

  • Make JSON method return types generic
interface ConfigInterface {
	a: string;
	b: number;
	c: {
		foo: string;
		bar: string;
	};
}

// before
let config = parseElementAsJson(htmlScriptTagElement) as ConfigInterface;
let otherConfig = safeParseJson("…") as ConfigInterface;

// after
let config = parseElementAsJson<ConfigInterface>(htmlScriptTagElement);
let otherConfig = safeParseJson<ConfigInterface>("…");

πŸ› Bug Fixes

  • Fixed broken enum check in network.ts's isStatusFailure()
  • Fixed automatic secure setting for cookies not properly inferring HTTPS status

Commits

  • Merge pull request #233 from Becklyn/generic-safeparsejson 0598ce9
  • Make JSON method return types generic c3eac4b
  • Merge pull request #230 from jesko-plitt/auto-secure-cookies-master 8909a55
  • Remove obsolete implementation c9380de
  • fix automatic secure setting for cookies d1d17ef
  • Change return type back to void instead of any, as we're doing nothing with the MountableFunction's return value 2c12a4e
  • Merge pull request #226 from Becklyn/mount-improvements 4eed328
  • Update changelog.md and upgrade.md 595ad16
  • Update JSDoc examples for mountLazy* functions e6b0b79
  • Rename generic parameters 4122cb2
  • Split doMount into specialized methods 466dd24
  • Add changelog for mount changes 33d8130
  • Split mount into mount, mountClass and mountJsx to improve type inference for required params 2e718c9
  • Upgrade preact RC and add ts-toolbelt 3ef4d61
  • Fixed broken enum check in isStatusFailure() (#224) a96275e
  • Fixed broken enum check in isStatusFailure() 29e88c9

https://github.com/Becklyn/mojave/compare/4.6.0...5.0.0

mojave -

Published by apfelbox about 5 years ago

Just a republish of 3.1.4 + 3.1.5, as the releases seem broken.

mojave -

Published by apfelbox about 5 years ago

⚠️ apparently also a broken release, try 3.1.6.

mojave -

Published by apfelbox about 5 years ago

⚠️ broken release, go directly to 3.1.5

πŸ› Bug Fixes

  • fix automatic cookie secure setting

Commits

  • Merge pull request #229 from jesko-plitt/auto-secure-cookies e48f0f5
  • fix code style in cookie.ts 537d170
  • fix automatic cookie secure setting 89e6853

https://github.com/Becklyn/mojave/compare/3.1.3...3.1.4

mojave -

Published by apfelbox about 5 years ago

🎁 New Features

  • Added more date formatter functions: formatDateTime() and formatDateTime().
  • Added a localized DateFormatter.

Commits

  • Add a localized DateFormatter (#228) 9879e93
  • Add a localized DateFormatter c79de84
  • Add more date formatter functions (#227) fef0433
  • Add more date formatter functions 7ddb3f5
  • Fixed broken enum check in isStatusFailure() (#224) a96275e
  • Fixed broken enum check in isStatusFailure() 29e88c9

https://github.com/Becklyn/mojave/compare/4.5.1...4.6.0

mojave -

Published by apfelbox about 5 years ago

✨ Improvements

  • Only show error in initFromGlobalData() if the element is not missing, but has an invalid structure. Ignore missing keys.

Commits

  • Ignore missing keys in initFromGlobalData() (#223) e6ea062
  • Ignore missing keys in initFromGlobalData() 5849190

https://github.com/Becklyn/mojave/compare/4.5.0...4.5.1

mojave -

Published by apfelbox about 5 years ago

🎁 New Features

  • Added inNextFrame() timing function.

πŸ› οΈ Internal

  • Consistently use mojave's own hasOwnProperty() in all of mojave's functions.

Commits

  • Add inNextFrame() (#222) 3714b00
  • Add inNextFrame() 031a17a
  • Use own hasOwnProperty throught the lib (#221) 91e8afa
  • Update PR template b7fde9f
  • Use own hasOwnProperty throught the lib d2cc144

https://github.com/Becklyn/mojave/compare/4.4.1...4.5.0

mojave -

Published by apfelbox about 5 years ago

✨ Improvements

  • Return initializer from initFromGlobalData().

Commits

  • Just testing sizereport... (#220) 37d4fe3
  • Update sizereport config 4f44610
  • Skip transient and fragile tests 63afeff
  • Return value from global data init 75b985b
  • Fix build for sizereport 24e2a58
  • Add changelog entry about toggleClass 2625bc2

https://github.com/Becklyn/mojave/compare/4.4.0...4.4.1

mojave -

Published by apfelbox about 5 years ago

🎁 New Features

  • Added initFromGlobalData().
  • Added toggleClass().

Commits

  • initFromGlobalData() + bump dependencies (#219) f395ba3
  • Add sizereport f8b1c06
  • Bump dependencies 99b07c7
  • Add types for qunit dce445e
  • Added initFromGlobalData() 6fc22d8
  • Merge pull request #218 from Becklyn/toggle-class c6e8197
  • Don't check if class already exists/doesn't exist 256a478
  • Add toggleClass 3d5e3e2

https://github.com/Becklyn/mojave/compare/4.3.2...4.4.0

Package Rankings
Top 7.82% on Npmjs.org
Related Projects