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

@teamawesome/access

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@teamawesome/access - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

.eslintrc.js

15

package.json
{
"name": "@teamawesome/access",
"version": "1.0.1",
"version": "1.0.2",
"description": "Provide an unified interface for objects.",
"keywords": ["map", "object", "array", "interface", "access"],
"keywords": [
"map",
"object",
"array",
"interface",
"access"
],
"main": "dist/index.js",

@@ -10,3 +16,5 @@ "scripts": {

"dev": "babel src --out-dir dist --watch --source-maps inline",
"test": "mocha"
"lint": "eslint src/",
"test": "mocha",
"prepublishOnly": "npm run-script lint && npm run-script test && npm run-script build"
},

@@ -22,2 +30,3 @@ "author": "Tom Hooijenga <tomhooijenga@gmail.com>",

"@babel/preset-env": "^7.0.0-beta.49",
"eslint": "^4.19.1",
"mocha": "^5.1.1",

@@ -24,0 +33,0 @@ "should": "^13.2.1",

26

README.md
# Installation
```
npm i @th/access
npm i @teamawesome/access
```

@@ -26,2 +26,5 @@

//
},
del(id) {
//
}

@@ -34,7 +37,10 @@ }

},
// etc
// Alias methods in one line:
delete: (obj, key) => obj.del(key)
});
```
If a type implements one of the used methods, it is not necessary to also add it to the handler. It will be called
automatically for you. For example, Map and WeakMap are fully compatible without being registered.
If a type implements one of the methods with the same signature, it is not necessary to add it to the handler. It
will be called automatically for you. For example, Map and WeakMap are fully compatible without being registered.
A proxied method has precedence over auto-detected methods.

@@ -44,7 +50,15 @@ ```

get(key) {
// Still called!
// Called automatically because it is detected.
},
set(key, value) {
// Not called automatically because it is proxied.
}
}
access.register(Type, {});
access.register(Type, {
set(obj, value) {
//
}
});
```
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