0.6.1 • Published 11 days ago

@stryke/helpers v0.6.1

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
11 days ago

Version Nx NextJs Commitizen friendly Semantic-Release documented with Fumadocs GitHub Workflow Status (with event)

!IMPORTANT Important This repository, and the apps, libraries, and tools contained within, is still in it's initial development phase. As a result, bugs and issues are expected with it's usage. When the main development phase completes, a proper release will be performed, the packages will be available through NPM (and other distributions), and this message will be removed. However, in the meantime, please feel free to report any issues you may come across.

Stryke - Helper Functions

A package containing miscellaneous helper functions that are used across many different Storm Software projects. This package is not meant to depend on any other Stryke projects.

Table of Contents

Quick Features

The following modules are available in this package:

  • arg-identity: Provides a function that returns its argument.
  • debounce: Provides a function to debounce another function, delaying its execution.
  • deep-clone: Provides a function to create a deep clone of an object.
  • deep-copy: Provides a function to create a deep copy of an object.
  • deep-merge: Provides a function to deeply merge two objects.
  • delay: Provides a function to delay execution for a specified amount of time.
  • flatten-object: Provides a function to flatten a nested object into a single level object.
  • get-field: Provides a function to get the value of a field from an object.
  • get-ordered-by: Provides a function to order an array of objects by a specified field.
  • get-unique: Provides a function to get unique values from an array.
  • identity: Provides a function that returns its argument.
  • is-equal: Provides a function to check if two values are deeply equal.
  • match-sorter: Provides a function to sort an array based on a search query.
  • noop: Provides a no-operation function.
  • remove-accents: Provides a function to remove accents from a string.
  • remove-empty-items: Provides a function to remove empty items from an array.
  • set-field: Provides a function to set the value of a field in an object.
  • throttle: Provides a function to throttle another function, limiting its execution rate.
  • timeout: Provides a function to execute another function with a timeout.
  • semaphore: Create a semaphore instance.
  • mutex: Create a mutex instance.
  • to-deep-key: Provides a function to convert a path to a deep key.
  • to-path: Provides a function to convert a deep key to a path.
  • unflatten-object: Provides a function to unflatten a single level object into a nested object.
  • union: Provides a function to create a union of two arrays.
  • with-timeout: Provides a function to execute another function with a timeout.

Installing

Using pnpm:

pnpm add -D @stryke/helpers
npm install -D @stryke/helpers
yarn add -D @stryke/helpers

Reduced Package Size

This project uses tsup to package the source code due to its ability to remove unused code and ship smaller javascript files thanks to code splitting. This helps to greatly reduce the size of the package and to make it easier to use in other projects.

Development

This project is built using Nx. As a result, many of the usual commands are available to assist in development.

Building

Run nx build helpers to build the library.

Running unit tests

Run nx test helpers to execute the unit tests via Jest.

Linting

Run nx lint helpers to run ESLint on the package.

Storm Workspaces

Storm workspaces are built using Nx, a set of extensible dev tools for monorepos, which helps you develop like Google, Facebook, and Microsoft. Building on top of Nx, the Open System provides a set of tools and patterns that help you scale your monorepo to many teams while keeping the codebase maintainable.

Roadmap

See the open issues for a list of proposed features (and known issues).

Support

Reach out to the maintainer at one of the following places:

License

This project is licensed under the Apache License 2.0. Feel free to edit and distribute this template as you like.

See LICENSE for more information.

Changelog

This project adheres to Semantic Versioning. Every release, along with the migration instructions, is documented in the CHANGELOG file

Contributing

First off, thanks for taking the time to contribute! Contributions are what makes the open-source community such an amazing place to learn, inspire, and create. Any contributions you make will benefit everybody else and are greatly appreciated.

Please try to create bug reports that are:

  • Reproducible. Include steps to reproduce the problem.
  • Specific. Include as much detail as possible: which version, what environment, etc.
  • Unique. Do not duplicate existing opened issues.
  • Scoped to a Single Bug. One bug per report.

Please adhere to this project's code of conduct.

You can use markdownlint-cli to check for common markdown style inconsistency.

Contributors

Thanks goes to these wonderful people (emoji key):

This project follows the all-contributors specification. Contributions of any kind welcome!

Storm Software is an open source software development organization and creator of Acidic, StormStack and StormCloud.

Our mission is to make software development more accessible. Our ideal future is one where anyone can create software without years of prior development experience serving as a barrier to entry. We hope to achieve this via LLMs, Generative AI, and intuitive, high-level data modeling/programming languages.

Join us on Discord to chat with the team, receive release notifications, ask questions, and get involved.

If this sounds interesting, and you would like to help us in creating the next generation of development tools, please reach out on our website or join our Slack channel!

0.4.5

3 months ago

0.5.3

1 month ago

0.4.4

3 months ago

0.4.6

3 months ago

0.5.0

3 months ago

0.6.1

11 days ago

0.5.2

2 months ago

0.4.3

3 months ago

0.6.0

26 days ago

0.5.1

3 months ago

0.4.1

3 months ago

0.4.0

3 months ago

0.4.2

3 months ago

0.3.0

4 months ago

0.3.1

4 months ago

0.2.4

4 months ago

0.2.3

4 months ago

0.2.2

4 months ago

0.2.1

4 months ago

0.2.0

4 months ago

0.1.5

4 months ago

0.1.4

4 months ago

0.1.0

4 months ago