How to use the coffee-script.helpers.updateSyntaxError 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 myou-engine / myou-engine / examples / multitouch / static_files / myou.js View on Github external
//This file is only needed by electron. myou.js is the packed project
//when the example.html is loaded from the browser.
var file_path = function(module, filename) {
  module.exports = 'file://' + filename.replace(/\\/g, '/');
};
for(var ext of ['.png', '.jpg', '.jpeg', '.gif', '.svg', '.woff']){
    require.extensions[ext] = file_path;
};
require('coffee-script/register');
var helpers = require('coffee-script').helpers, use = helpers.updateSyntaxError;
helpers.updateSyntaxError = function(e,c,f){
    return use(e, c, f).toString();
}
require('../main.coffee');
github myou-engine / myou-engine / examples / multitouch / static_files / myou.js View on Github external
//This file is only needed by electron. myou.js is the packed project
//when the example.html is loaded from the browser.
var file_path = function(module, filename) {
  module.exports = 'file://' + filename.replace(/\\/g, '/');
};
for(var ext of ['.png', '.jpg', '.jpeg', '.gif', '.svg', '.woff']){
    require.extensions[ext] = file_path;
};
require('coffee-script/register');
var helpers = require('coffee-script').helpers, use = helpers.updateSyntaxError;
helpers.updateSyntaxError = function(e,c,f){
    return use(e, c, f).toString();
}
require('../main.coffee');