Sha256: 88749c10ed988f09ded718619b0bed19bcee722e846df0091f2fdf9d83018515

Contents?: true

Size: 600 Bytes

Versions: 56

Compression:

Stored size: 600 Bytes

Contents

'use strict';


var yaml = require('../lib/js-yaml');
var object = require('./dumper.json');


console.log(yaml.dump(object, {
  flowLevel: 3,
  styles: {
    '!!int'  : 'hexadecimal',
    '!!null' : 'camelcase'
  }
}));


// Output:
//==============================================================================
// name: Wizzard
// level: 0x11
// sanity: Null
// inventory:
//   - name: Hat
//     features: [magic, pointed]
//     traits: {}
//   - name: Staff
//     features: []
//     traits: {damage: 0xA}
//   - name: Cloak
//     features: [old]
//     traits: {defence: 0x0, comfort: 0x3}

Version data entries

56 entries across 42 versions & 5 rubygems

Version Path
opal-0.9.0.beta2 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-0.9.0.beta1 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-0.8.1 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-0.8.1.rc1 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-wedge-0.9.0.dev stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-0.8.0 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-0.8.0.rc3 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-0.8.0.rc2 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-0.8.0.rc1 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-0.8.0.beta1 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
opal-0.7.2 stdlib/nodejs/node_modules/js-yaml/examples/dumper.js
entangled-0.0.16 spec/dummy/public/node_modules/grunt/node_modules/js-yaml/examples/dumper.js
entangled-0.0.16 spec/dummy/public/node_modules/bower/node_modules/update-notifier/node_modules/configstore/node_modules/js-yaml/examples/dumper.js
entangled-0.0.16 spec/dummy/public/node_modules/bower/node_modules/insight/node_modules/configstore/node_modules/js-yaml/examples/dumper.js
entangled-0.0.15 spec/dummy/public/node_modules/bower/node_modules/update-notifier/node_modules/configstore/node_modules/js-yaml/examples/dumper.js
entangled-0.0.15 spec/dummy/public/node_modules/grunt/node_modules/js-yaml/examples/dumper.js
entangled-0.0.15 spec/dummy/public/node_modules/bower/node_modules/insight/node_modules/configstore/node_modules/js-yaml/examples/dumper.js
entangled-0.0.14 spec/dummy/public/node_modules/grunt/node_modules/js-yaml/examples/dumper.js
entangled-0.0.14 spec/dummy/public/node_modules/bower/node_modules/update-notifier/node_modules/configstore/node_modules/js-yaml/examples/dumper.js
entangled-0.0.14 spec/dummy/public/node_modules/bower/node_modules/insight/node_modules/configstore/node_modules/js-yaml/examples/dumper.js