UNPKG

react-crossroads

Version:

Client side router for web applications built with React and utilizing the Flux architecture. The backing routing engine is CrossroadsJs.

27 lines (24 loc) 564 B
var logger; logger = function(condition) { return { log: function(message) { if (condition) { return console.log(message); } }, warn: function(message) { if (condition) { return console.warn(message); } }, error: function(message) { if (condition) { return console.error(message); } } }; }; module.exports = { debug: logger((typeof DEBUG_ROUTING !== "undefined" && DEBUG_ROUTING !== null) && DEBUG_ROUTING), development: logger(process.env.NODE_ENV === 'production') };