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

djinn-state

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

djinn-state - npm Package Compare versions

Comparing version 0.0.2 to 0.1.0

1

dist/Djinn.d.ts

@@ -33,2 +33,3 @@ import { DjinnService } from './DjinnService';

getService: <T>(service: new () => T) => T;
remove(service: any): void;
}

@@ -35,0 +36,0 @@ interface IDjinnServiceRegister {

@@ -78,4 +78,8 @@ "use strict";

}
Djinn.prototype.remove = function (service) {
var serviceName = service.name;
delete this.__services[serviceName];
};
return Djinn;
}());
exports.Djinn = Djinn;

4

package.json
{
"name": "djinn-state",
"version": "0.0.2",
"version": "0.1.0",
"description": "Powerful yet simple state machine",
"main": "dist/index.js",
"repository": "https://github.com/djinn-state/djinn-state.git",
"author": "Gilmar Quinelato <gilmarsquinelato@gmail.com>",
"license": "MIT",

@@ -7,0 +9,0 @@ "scripts": {

# Djinn-state
[![Build Status](https://travis-ci.com/gilmarsquinelato/djinn-state.svg?branch=master)](https://travis-ci.com/gilmarsquinelato/djinn-state)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/dc067eab06d44cedbbc2dfceeeb8ec38)](https://www.codacy.com/app/gilmarsquinelato/djinn-state?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=gilmarsquinelato/djinn-state&amp;utm_campaign=Badge_Grade)
[![Codacy Badge](https://api.codacy.com/project/badge/Coverage/dc067eab06d44cedbbc2dfceeeb8ec38)](https://www.codacy.com/app/gilmarsquinelato/djinn-state?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=gilmarsquinelato/djinn-state&amp;utm_campaign=Badge_Coverage)
[![Build Status](https://travis-ci.com/djinn-state/djinn-state.svg?branch=master)](https://travis-ci.com/djinn-state/djinn-state)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/dc067eab06d44cedbbc2dfceeeb8ec38)](https://www.codacy.com/app/djinn-state/djinn-state?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=gilmarsquinelato/djinn-state&amp;utm_campaign=Badge_Grade)
[![Codacy Badge](https://api.codacy.com/project/badge/Coverage/dc067eab06d44cedbbc2dfceeeb8ec38)](https://www.codacy.com/app/djinn-state/djinn-state?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=gilmarsquinelato/djinn-state&amp;utm_campaign=Badge_Coverage)
[![](https://img.shields.io/david/gilmarsquinelato/djinn-state.svg)](https://github.com/gilmarsquinelato/djinn-state)
[![](https://img.shields.io/david/djinn-state/djinn-state.svg)](https://github.com/djinn-state/djinn-state)
[![](https://img.shields.io/npm/dw/djinn-state.svg)](https://www.npmjs.com/package/djinn-state)

@@ -12,3 +12,3 @@ [![](https://img.shields.io/bundlephobia/minzip/djinn-state.svg)](https://www.npmjs.com/package/djinn-state)

A powerful yet simple state machine.
A powerful yet simple application state management.

@@ -15,0 +15,0 @@ The Djinn-state was developed with the objective to be less verbose and simple to maintain and scale Javascript applications.

@@ -76,2 +76,12 @@ import { Djinn} from '../Djinn';

});
it('should remove a service', () => {
const djinn = new Djinn();
djinn.register(FakeService);
djinn.remove(FakeService);
const services = djinn.getRegisteredServices();
expect(Object.keys(services).length).toBe(0);
});
});

@@ -76,2 +76,7 @@ import { DjinnService } from './DjinnService';

};
remove(service: any) {
const serviceName = (<any>service).name;
delete this.__services[serviceName];
}
}

@@ -78,0 +83,0 @@

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