Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
import middleware from './middleware';
import services from './services';
import appHooks from './app.hooks';
import channels from './channels';
// tslint:disable-next-line
const generatorSpecs = require('../feathers-gen-specs.json');
import authentication from './authentication';
// !code: imports // !end
// !code: init // !end
const app = express(feathers());
// !code: use_start // !end
// Load app configuration
app.configure(configuration());
// ! code: init_config
app.set('generatorSpecs', generatorSpecs);
// !end
// Enable security, CORS, compression, favicon and body parsing
app.use(helmet(
// !code: helmet_config // !end
));
app.use(cors(
// !code: cors_config // !end
));
app.use(compress(
// !code: compress_config // !end
));
app.use(express.json(
// !code: json_config // !end
import middleware from './middleware';
import services from './services';
import appHooks from './app.hooks';
import channels from './channels';
// tslint:disable-next-line
const generatorSpecs = require('../feathers-gen-specs.json');
import authentication from './authentication';
// !code: imports // !end
// !code: init // !end
const app = express(feathers());
// !code: use_start // !end
// Load app configuration
app.configure(configuration());
// ! code: init_config
app.set('generatorSpecs', generatorSpecs);
// !end
// Enable security, CORS, compression, favicon and body parsing
app.use(helmet());
app.use(cors());
app.use(compress());
app.use(express.json());
app.use(express.urlencoded({ extended: true }));
app.use(favicon(path.join(app.get('public'), 'favicon.ico')));
// Host the public folder
app.use('/', express.static(app.get('public')));
// !code: use_end // !end
// Set up Plugins and providers
import services from './services';
import appHooks from './app.hooks';
import channels from './channels';
// tslint:disable-next-line
const generatorSpecs = require('../feathers-gen-specs.json');
import authentication from './authentication';
import mongoose from './mongoose';
// !code: imports // !end
// !code: init // !end
const app = express(feathers());
// !code: use_start // !end
// Load app configuration
app.configure(configuration());
// ! code: init_config
app.set('generatorSpecs', generatorSpecs);
// !end
// Enable security, CORS, compression, favicon and body parsing
app.use(helmet());
app.use(cors());
app.use(compress());
app.use(express.json());
app.use(express.urlencoded({ extended: true }));
app.use(favicon(path.join(app.get('public'), 'favicon.ico')));
// Host the public folder
app.use('/', express.static(app.get('public')));
// !code: use_end // !end
// Set up Plugins and providers
import services from './services';
import appHooks from './app.hooks';
import channels from './channels';
// tslint:disable-next-line
const generatorSpecs = require('../feathers-gen-specs.json');
import authentication from './authentication';
import mongoose from './mongoose';
// !code: imports // !end
// !code: init // !end
const app = express(feathers());
// !code: use_start // !end
// Load app configuration
app.configure(configuration());
// ! code: init_config
app.set('generatorSpecs', generatorSpecs);
// !end
// Enable security, CORS, compression, favicon and body parsing
app.use(helmet(
// !code: helmet_config // !end
));
app.use(cors(
// !code: cors_config // !end
));
app.use(compress(
// !code: compress_config // !end
));
app.use(express.json(
// !code: json_config // !end
import services from './services';
import appHooks from './app.hooks';
import channels from './channels';
// tslint:disable-next-line
const generatorSpecs = require('../feathers-gen-specs.json');
import authentication from './authentication';
import mongodb from './mongodb';
// !code: imports // !end
// !code: init // !end
const app = express(feathers());
// !code: use_start // !end
// Load app configuration
app.configure(configuration());
// ! code: init_config
app.set('generatorSpecs', generatorSpecs);
// !end
// Enable security, CORS, compression, favicon and body parsing
app.use(helmet(
// !code: helmet_config // !end
));
app.use(cors(
// !code: cors_config // !end
));
app.use(compress(
// !code: compress_config // !end
));
app.use(express.json(
// !code: json_config // !end
import express from '@feathersjs/express';
import { Application } from './declarations';
import logger from './logger';
import middleware from './middleware';
import services from './services';
import appHooks from './app.hooks';
import channels from './channels';
import authentication from './authentication';
import mongoose from './mongoose';
// Don't remove this comment. It's needed to format import lines nicely.
const app: Application = express(feathers());
// Load app configuration
app.configure(configuration());
// Enable security, CORS, compression, favicon and body parsing
app.use(helmet());
app.use(cors());
app.use(compress());
app.use(express.json());
app.use(express.urlencoded({ extended: true }));
app.use(favicon(path.join(app.get('public'), 'favicon.ico')));
// Host the public folder
app.use('/', express.static(app.get('public')));
// Set up Plugins and providers
app.configure(express.rest());
app.configure(mongoose);
import services from './services';
import appHooks from './app.hooks';
import channels from './channels';
// tslint:disable-next-line
const generatorSpecs = require('../feathers-gen-specs.json');
import authentication from './authentication';
import mongoose from './mongoose';
// !code: imports // !end
// !code: init // !end
const app = express(feathers());
// !code: use_start // !end
// Load app configuration
app.configure(configuration());
// ! code: init_config
app.set('generatorSpecs', generatorSpecs);
// !end
// Enable security, CORS, compression, favicon and body parsing
app.use(helmet());
app.use(cors());
app.use(compress());
app.use(express.json());
app.use(express.urlencoded({ extended: true }));
app.use(favicon(path.join(app.get('public'), 'favicon.ico')));
// Host the public folder
app.use('/', express.static(app.get('public')));
// !code: use_end // !end
// Set up Plugins and providers
import socketio from '@feathersjs/socketio';
import { Application } from './declarations';
import logger from './logger';
import middleware from './middleware';
import services from './services';
import appHooks from './app.hooks';
import channels from './channels';
import authentication from './authentication';
// Don't remove this comment. It's needed to format import lines nicely.
const app: Application = express(feathers());
// Load app configuration
app.configure(configuration());
if (process.env.INSIGHTS_DATA) {
app.set('nedb', process.env.INSIGHTS_DATA)
}
// Enable security, CORS, compression, favicon and body parsing
app.use(helmet());
app.use(cors());
app.use(compress());
app.use(express.json());
app.use(express.urlencoded({ extended: true }));
app.use(favicon(path.join(app.get('public'), 'favicon.ico')));
// Host the public folder
app.use('/', express.static(app.get('public')));
// Set up Plugins and providers
import socketio from '@feathersjs/socketio';
import swagger from 'feathers-swagger';
import { Application } from './declarations';
import logger from './logger';
import middleware from './middleware';
import services from './services';
import appHooks from './app.hooks';
import channels from './channels';
import authentication from './authentication';
// Don't remove this comment. It's needed to format import lines nicely.
const app: Application = express(feathers());
// Load app configuration
app.configure(configuration());
// Enable security, CORS, compression, favicon and body parsing
app.use(helmet());
app.use(cors());
app.use(compress());
app.use(express.json());
app.use(express.urlencoded({ extended: true }));
app.use(favicon(path.join(app.get('public'), 'favicon.ico')));
// Host the public folder
app.use(express.static(app.get('public')));
// Set up Plugins and providers
app.configure(express.rest());
app.configure(socketio());
app.configure(
swagger({
docsPath: '/api/docs',
import feathers, { Application } from '@feathersjs/feathers';
import feathersConfiguration from '@feathersjs/configuration';
const app: Application = feathers().configure(feathersConfiguration());