New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@gulujs/toml

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@gulujs/toml

TOML parser and serializer

latest
Source
npmnpm
Version
0.4.1
Version published
Maintainers
1
Created
Source

@gulujs/toml

TOML parser and serializer

Compatible with TOML version v1.0.0.

The module passes the TOML test suite, except for the following three test case:

The reason:

  • JavaScript does not define different types of numbers, like integers, short, long, floating-point etc. So @gulujs/toml doesn't preserve type information between integers and floats.
  • TomlDate is inherited from JavaScript Date object, the precision of the Date object in JavaScript is typically in milliseconds.

Installation

npm install @gulujs/toml

Usage

import * as fs from 'fs';
import * as TOML from '@gulujs/toml';

const source = fs.readFileSync('/path/to/file.toml', { encoding: 'utf-8' });
const config = TOML.parse(source);
console.log(config);

console.log(TOML.stringify(config));

License

MIT

Keywords

TOML

FAQs

Package last updated on 12 Nov 2023

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