Miss any of our Open RFC calls?Watch the recordings here! »

@yarnpkg/lockfile

1.1.0 • Public • Published

yarn-lockfile

Parse and/or write yarn.lock files

Usage Examples

const fs = require('fs');
const lockfile = require('@yarnpkg/lockfile');
// or (es6)
import fs from 'fs';
import * as lockfile from '@yarnpkg/lockfile';
 
let file = fs.readFileSync('yarn.lock', 'utf8');
let json = lockfile.parse(file);
 
console.log(json);
 
let fileAgain = lockfile.stringify(json);
 
console.log(fileAgain);

Install

npm i @yarnpkg/lockfile

DownloadsWeekly Downloads

1,763,735

Version

1.1.0

License

BSD-2-Clause

Unpacked Size

280 kB

Total Files

4

Last publish

Collaborators

  • avatar
  • avatar
  • avatar
  • avatar
  • avatar