Add some error messages for the developer when .service.js is malformed When loading `.service.js` files which don’t contain services, such as when the export is forgotten, print helpful error messages. This will only occur during development; the unit tests will catch these problems well before code reaches the server.
10 lines
279 B
JavaScript
10 lines
279 B
JavaScript
'use strict'
|
|
|
|
const BaseJsonService = require('../services/base-json')
|
|
const LegacyService = require('../services/legacy-service')
|
|
|
|
class GoodServiceOne extends BaseJsonService {}
|
|
class GoodServiceTwo extends LegacyService {}
|
|
|
|
module.exports = { GoodServiceOne, GoodServiceTwo }
|