diff options
author | Jérémy Faivre <jeremy.faivre@gmail.com> | 2014-09-14 15:31:50 +0200 |
---|---|---|
committer | Jérémy Faivre <jeremy.faivre@gmail.com> | 2014-09-14 15:32:00 +0200 |
commit | 65ff8d1cca3ad308bf608c0b3f663df974693ef9 (patch) | |
tree | 5962a626a2effd0dec8f4dcdf17ad53a034e923c /index.js | |
parent | ffe715eb2ff31db93cf36d28728e03dd28a84381 (diff) | |
download | yamljs-65ff8d1cca3ad308bf608c0b3f663df974693ef9.tar.gz |
Cleanup index.js
Diffstat (limited to 'index.js')
-rw-r--r-- | index.js | 21 |
1 files changed, 1 insertions, 20 deletions
@@ -1,22 +1,3 @@ var Yaml = require('./lib/Yaml'); - -// Compatibility layer with previous version of yaml.js -// That was exposing the YAML library as global object in the browser -if (typeof(window) != 'undefined') { - window.YAML = { - parse: function(input, exceptionOnInvalidType, objectDecoder) { - return Yaml.parse(input, exceptionOnInvalidType, objectDecoder); - }, - - stringify: function(array, inline, indent, exceptionOnInvalidType, objectEncoder) { - return Yaml.dump(array, inline, indent, exceptionOnInvalidType, objectEncoder); - } - }; -} - -module.exports = { - Yaml: require('./lib/Yaml'), - Parser: require('./lib/Parser'), - Dumper: require('./lib/Dumper') -}; +module.exports = Yaml; |