shared-preact-rollup
v4.0.0
Published
Library exclusively used by Audio Intakes UI components.
Downloads
1
Readme
Getting started
About
This is shared library exclusively intended for developers working at Audio Intakes (@audio-intakes). It includes custom hooks, utility functions, components and configuration files all consumed by Audio Intakes UI components (Editor, Recorder, Player).
Installation
This is a public package scoped of the audio-intakes NPM organization.
npm install --save @audio-intakes/shared
or
yarn add @audio-intakes/shared
Importing
A hook
import { useIsMount } from "@audio-intakes/shared"
A utility Function
import { validateID } from "@audio-intakes/shared"
A configuration constant
import { themeNames } from "@audio-intakes/shared"
Usage
A hook
const isMount = useIsMount()
A utility Function
const validatedID = validateID(id)
A configuration constant
const arr = themes.map(t => t)
Content
Hooks
Inspiration:
Some inspirational repositories to keep tracking for new ideas:
react-hooks: https://react-hooks.org rooks: https://github.com/imbhargav5/rooks react-use: https://github.com/streamich/react-use
- useBrowserStorage
- useDeviceDetect
- useGeoLocation
- useIsMount
- useMetaData
- useOnOutsideClick
- useResizeContainer
- useScreenOrientation
- useWafeSurfer
Utils
Configs
Components
Motivation
License
Contributing
See the CONTRIBUTING.md