![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Beautiful, light and simple state manager inspired by Redux
import Store from 'delux';
let store = new Store ();
store.tasks = new Store.Collection ({tasks: []});
store.tasks.on('addTask', (tasks, action) => tasks.concat({
name: action.payload,
completed: false
}));
store.observe('tasks', (state) => console.log(state.tasks));
store.dispatch({
type: 'addTask',
payload: 'Try Delux'
});
The Store holds the whole application state and it's mutation logic.
let store = new Store();
Stores are objects whose prototype has methods to mutate there state. The Store's state is hold in Collections assigned to it.
Returns an object with mutations of the collections' states
Dispatches a Flux Standard Action on the state
store.dispatch({
type: <string | symbol>,
payload: <object>
error: <boolean>,
meta: <any>
});
Returns
The mutated store state
Adds an observer for mutations in the store's collections
store.observe(['collectionName'], (state) => {
});
Parameters
Name | Supplied Value |
---|---|
state | Store.prototype.state alias |
Adds a middlware to the action resolution process
store.use((action) => {
});
Parameters
Adds a function to the store's execute queue
store.queue(() => callback());
Get specific collection's state from the store's state
let partialState = store.state.get(collectionNames);
Collections holds a sub-state (similar to Flux Stores) and it's mutation logic
store.collectionName = new Collection (init);
Parameters
Reflects the collections's state
Reflects the collections's reducers
Reflects the collections's observers
Attach a reducer to received actions (Node style)
store.collectionName.on(['actionType'], (state, action) => {
});
Parameters
Name | Supplied Value |
---|---|
state | The collection state |
action | The dispatched action |
FAQs
Beautiful, light and simple state manager inspired by Redux
The npm package delux receives a total of 18 weekly downloads. As such, delux popularity was classified as not popular.
We found that delux demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.