development.js 458 B

123456789101112131415161718
  1. const path = require('path');
  2. const Application = require('thinkjs');
  3. const watcher = require('think-watcher');
  4. const babel = require('think-babel');
  5. const notifier = require('node-notifier');
  6. const instance = new Application({
  7. ROOT_PATH: __dirname,
  8. APP_PATH: path.join(__dirname, 'app'),
  9. watcher: watcher,
  10. transpiler: [babel, {
  11. presets: ['think-node']
  12. }],
  13. notifier: notifier.notify.bind(notifier),
  14. env: 'development'
  15. });
  16. instance.run();