Skip to content

Prits001/molprint

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

npm version npm downloads

MolPrint NPM Package

Npm package providing random chemical compounds.

Installation

npm install molprint

Use

  1. Import the package function..

    import getCompound from "molprint";
  2. Call the imported function..

    const compound = getCompound();
    console.log(compound);

    This will output a random chemical compound with description to the console.

    getCompound() has an optional boolean parameter detailed: true by default.

    If detailed: false, only the compound will be output, without description.

    import getCompound from "./index.js";
    console.log(getCompound(false)); 
    //Out: { compound: 'Ethanol (C2H5OH)' }

If you'd like to contribute, feel free to submit a pull request.

About

Prints random chemical compound.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published