🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

node-osc

Package Overview
Dependencies
Maintainers
1
Versions
99
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-osc - npm Package Compare versions

Comparing version

to
5.0.0-beta.0

dist/bundle.js

2

examples/client.js
/* eslint-disable no-console */
'use strict';
const { Client, Message } = require('../lib');
const { Client, Message } = require('node-osc');

@@ -6,0 +6,0 @@ const client = new Client('127.0.0.1', 3333);

/* eslint-disable no-console */
'use strict';
var { Server } = require('../lib');
var { Server } = require('node-osc');

@@ -6,0 +6,0 @@ var oscServer = new Server(3333, '0.0.0.0');

{
"name": "node-osc",
"description": "pyOSC inspired library",
"version": "4.1.4",
"main": "lib/index.js",
"version": "5.0.0-beta.0",
"main": "./dist/bundle.js",
"exports": {
".": "lib/index.js",
"./": "./",
"esm": "lib/index.mjs"
"default": "./lib/index.mjs",
"require": "./dist/bundle.js"
},

@@ -16,11 +15,13 @@ "author": {

"engines": {
"node": ">=8"
"node": ">=12"
},
"license": "LGPL-2.1",
"scripts": {
"test": "npm run lint && npm run tap",
"tap": "tap test/test-*.js",
"build": "rollup --config rollup.config.mjs",
"prepublishOnly": "npm run build",
"test": "npm run lint && npm run build && npm run tap",
"tap": "tap --no-esm --node-arg=--experimental-modules test/test-*{.js,.mjs}",
"coverage": "npm run tap -- --coverage",
"coverage-html": "npm run tap -- --coverage-report=html",
"lint": "eslint **/*.js"
"lint": "eslint lib/* test/* examples/*"
},

@@ -46,4 +47,5 @@ "contributors": [

"eslint": "^6.0.1",
"rollup": "^1.27.9",
"tap": "^14.6.1"
}
}

@@ -11,2 +11,6 @@ # node-osc

## ⚠️ Experimental ⚠️
This is an experimental ESM version of node-osc make sure to run node with the `--experimental-modules` flag. This version require at minimum Node.js 13.2.0
## Example

@@ -17,3 +21,3 @@

```js
const { Client } = require('node-osc');
import { Client } from 'node-osc';

@@ -29,3 +33,3 @@ const client = new Client('127.0.0.1', 3333);

```js
var { Server } = require('../lib');
import { Server } from 'node-osc';

@@ -40,6 +44,8 @@ var oscServer = new Server(3333, '0.0.0.0');

### Now with ESM!
### Legacy API
This just works due to conditional exports, isn't that cool!
```js
import { Client, Server } from 'node-osc/esm'
const { Client, Server } = require('node-osc');

@@ -46,0 +52,0 @@ const client = new Client('127.0.0.1', 3333);

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