Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

normalize-stats

kmalakoff324MIT1.1.0TypeScript support: included

Create BigIntStats from fs.Stats for compatibility on earlier versions of Node.js

dirent, fs.Dirent, stats, fs.Stats, compatibility, es5

readme

normalize-stats

Normalize fs.Stats and fs.BigIntStats across versions of Node.js.

var assert = require('assert');
var normalize = require('normalize-stats');
var fs = require('fs');

var smallStats = normalize(fs.statSync(__dirname));

var bigStats = normalize(fs.lstatSync(__dirname, { bigint: true }));