How to use the coffee-script/lib/coffee-script/helpers.flatten function in coffee-script

To help you get started, we’ve selected a few coffee-script examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github tower / tower / coffee-inheritance.js View on Github external
var helpers = require('coffee-script/lib/coffee-script/helpers');
var Literal = nodes.Literal;
var Extends = nodes.Extends;
var Code = nodes.Code;
var Class = nodes.Class;
var Param = nodes.Param;
var Block = nodes.Block;
var Call = nodes.Call;
var Assign = nodes.Assign;
var Value = nodes.Value;
var Parens = nodes.Parens;
var Access = nodes.Access;
var If = nodes.If;
var Arr = nodes.Arr;
var compact = helpers.compact;
var flatten = helpers.flatten;
var extend = helpers.extend;
var merge = helpers.merge;
var del = helpers.del;
var starts = helpers.starts;
var ends = helpers.ends;
var last = helpers.last;

var LEVEL_TOP = 1;
var LEVEL_PAREN = 2;
var LEVEL_LIST = 3;
var LEVEL_COND = 4;
var LEVEL_OP = 5;
var LEVEL_ACCESS = 6;
var TAB = '  ';
var IDENTIFIER_STR = "[$A-Za-z_\\x7f-\\uffff][$\\w\\x7f-\\uffff]*";
var IDENTIFIER = RegExp("^" + IDENTIFIER_STR + "$");