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

alinex-format

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

alinex-format

Parse and format multiple data serialization types.

latest
Source
npmnpm
Version
1.2.0
Version published
Maintainers
1
Created
Source

Alinex Format: Readme

GitHub watchers

GitHub stars GitHub forks

npm package latest version

Travis status Coveralls status Gemnasium status GitHub issues

This package will give you an easy way to serialize and deserialize different data objects into multiple formats.

The major features are:

  • easy to use
  • load format libraries on demand
  • auto detection

It is one of the modules of the Alinex Namespace following the code standards defined in the General Docs.

Read the complete documentation under https://alinex.github.io/node-format.

Install

NPM Downloads

The easiest way is to let npm add the module directly to your modules (from within you node modules directory):

npm install alinex-format --save

And update it to the latest version later:

npm update alinex-format --save

Always have a look at the latest changes.

Usage

To use the format you have to load the module first:

format = require 'alinex-format'

This gives you back the main format instance which holds two methods to use:

stringify

Serialize data object into string.

Arguments:

  • obj object to be formatted
  • format format to use or filename to read format from
  • options (optional) specific for the format
  • cb callback will be called with (err, text)

parse

Try to parse object from string. Auto detect if no format is given.

Arguments:

  • string text to be parsed
  • format (optional) format to use or filename to read format from
  • cb callback will be called with (err, object)

License

(C) Copyright 2016 Alexander Schilling

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Keywords

serialization

FAQs

Package last updated on 18 Apr 2017

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