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

@dojo/shim

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@dojo/shim - npm Package Compare versions

Comparing version 2.0.0-beta.10 to 2.0.0-beta.11

12

package.json
{
"name": "@dojo/shim",
"version": "2.0.0-beta.10",
"version": "2.0.0-beta.11",
"description": "Modules that provide modular fills of ES6+ functionality",

@@ -11,2 +11,5 @@ "homepage": "http://dojotoolkit.org",

"main": "main.js",
"engines": {
"npm": ">=3.0.0"
},
"repository": {

@@ -17,6 +20,6 @@ "type": "git",

"peerDependencies": {
"@dojo/has": "2.0.0-alpha.8"
"@dojo/has": "^2.0.0-alpha.8"
},
"devDependencies": {
"@dojo/loader": "2.0.0-beta.9",
"@dojo/loader": "^2.0.0-beta.9",
"@types/chai": "~3.4.0",

@@ -27,8 +30,7 @@ "@types/glob": "~5.0.0",

"grunt": "~1.0.1",
"grunt-dojo2": ">=2.0.0-beta.22",
"grunt-dojo2": ">=2.0.0-beta.36",
"intern": "^3.4.1",
"istanbul": "^0.4.3",
"tslint": "^3.15.1",
"typescript": "~2.2.1"
}
}

@@ -18,6 +18,35 @@ # @dojo/shim

## Usage
To use `@dojo/shim`, install the package along with its required peer dependencies:
```bash
npm install @dojo/shim
# peer dependencies
npm install @dojo/has
```
## Features
TODO: Add sections on features of this package
Many of the features in this package will fallback to a native implementation if one is available.
- [Array](#array-methods)
- [Data Structures](#data-structures)
- [Map](#map)
- [Set](#set)
- [WeakMap](#weakmap)
- [Iterators](#iterators)
- [Math](#math)
- [Number](#number)
- [Object](#object)
- [Observables](#observables)
- [Promises](#promises)
- [String](#string)
- [Symbols](#symbols)
### Array Methods
[`@dojo/shim/array`](docs/array.md) provides implementations of many array utilities.
### Data Structures

@@ -30,2 +59,23 @@

#### Set
The `@dojo/shim/Set` class is an implementation of the [ES2015 Set specification](http://www.ecma-international.org/ecma-262/6.0/#sec-set-objects). A Set is used to a collection of unique values.
```typescript
import Set from '@dojo/shim/Set';
const values = new Set<string>();
values.add('one');
values.add('two');
values.add('one');
values.forEach((value) => {
console.log(value);
});
// output:
// one
// two
```
#### WeakMap

@@ -40,7 +90,46 @@

### Iterators
## How do I use this package?
The `@dojo/shim/iterator` module is an implementation of the [ES2015 Iterator specification](http://www.ecma-international.org/ecma-262/6.0/#sec-iteration).
TODO: Add appropriate usage and instruction guidelines
### Math
The [`@dojo/shim/math`](docs/math.md) module provides implementations for many math methods.
### Number
The `dojo/shim/number` module provides implementations for several `Number` methods.
* `isNaN`
* `isFinite`
* `isInteger`
* `isSafeInteger`
### Object
The `dojo/shim/object` provides implementations of `Object` methods.
* is
* getOwnPropertySymbols
* getOwnPropertyNames
* getOwnPropertyDescriptor
* values
* entries
### Observables
The [`@dojo/shim/Observable`](docs/Observable.md) class is an implementation of the proposed [Observable specification](https://tc39.github.io/proposal-observable/). Observables are further extended in [`@dojo/core/Observable`](https://github.com/dojo/core/blob/master/src/Observable.ts).
### Promises
[`@dojo/shim/Promise`](docs/Promise.md) is an implementation of the [ES2015 Promise specification](http://www.ecma-international.org/ecma-262/6.0/#sec-promise-objects).
### String
The [`@dojo/shim/string`](docs/string.md) module contains `String` methods.
### Symbols
`@dojo/shim/Symbol` provides an implementation of the [ES2015 Symbol specification](http://www.ecma-international.org/ecma-262/6.0/#sec-symbol-objects) for environments that do not natively support `Symbol`.
## How do I contribute?

@@ -51,4 +140,10 @@

## Testing
### Installation
To start working with this package, clone the repository and run `npm install`.
In order to build the project run `grunt dev` or `grunt dist`.
### Testing
Test cases MUST be written using [Intern](https://theintern.github.io) using the Object test interface and Assert assertion interface.

@@ -76,7 +171,3 @@

TODO: If third-party code was used to write this library, make a list of project names and licenses here
* [Third-party lib one](https//github.com/foo/bar) ([New BSD](http://opensource.org/licenses/BSD-3-Clause))
© [JS Foundation](https://js.foundation/) & contributors. [New BSD](http://opensource.org/licenses/BSD-3-Clause) license.

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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