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

@devsnowflake/morsecode.js

Package Overview
Dependencies
Maintainers
2
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@devsnowflake/morsecode.js

Simple package to encode/decode morse code

  • 1.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
2
Created
Source

MorseCode.JS

Simple package to encode/decode morse code.

Installing

$ npm i @devsnowflake/morsecode.js

Example

Encoder

const morse = require("@devsnowflake/morsecode.js");
const message = "This is my message";

const mc = morse.Encode(message);
console.log(mc);
// - .... .. ... / .. ... / -- -.-- / -- . ... ... .- --. .

Decoder

const morse = require("@devsnowflake/morsecode.js");
const mc = "- .... .. ... / .. ... / -- -.-- / -- . ... ... .- --. .";

const message = morse.Decode(mc);
console.log(mc);
// this is my message

Audio Encoder

Note: Audio encoder is currently not accurate and might not work properly.

const morse = require("@devsnowflake/morsecode.js");
const fs = require("fs");
const message = "This is my message";

const mc = morse.Encode(message);
const audio = morse.CreateAudio(mc);

audio.pipe(fs.createWriteStream("./morse.mp3"));

Join my Discord

Keywords

FAQs

Package last updated on 01 Dec 2020

Did you know?

Socket

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.

Install

Related posts

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