Skip to content

Instantly share code, notes, and snippets.

@arsenetoumani arsenetoumani/app.js Secret
Created Feb 28, 2019

Embed
What would you like to do?
'use strict';
require("./app-styles"); // get app styles
require("../src/app/app.module"); // get app module
function importAll(r) {
r.keys().forEach(r);
}
// get all of the app's js and jsx files - excluding modules and spec files
importAll(
require.context("../src/app/", true, /^(?!.*\.module\.js$)^(?!.*\.(spec|test)\.(js|jsx)$).*\.(js|jsx)$/)
);
require('./app-templates'); // get app's templates
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.