Initial ember app

This commit is contained in:
Daniil Borovkov 2018-12-04 13:26:07 +06:00
parent 793ba76ac4
commit f409dec68f
15 changed files with 104 additions and 1 deletions

View File

@ -1,3 +1,4 @@
{ {
"disableAnalytics": false "disableAnalytics": false,
"output_path": "dist"
} }

14
app/app.js Normal file
View File

@ -0,0 +1,14 @@
import Application from '@ember/application';
import Resolver from './resolver';
import loadInitializers from 'ember-load-initializers';
import config from './config/environment';
const App = Application.extend({
modulePrefix: config.modulePrefix,
podModulePrefix: config.podModulePrefix,
Resolver
});
loadInitializers(App, config.modulePrefix);
export default App;

0
app/controllers/.gitkeep Normal file
View File

0
app/helpers/.gitkeep Normal file
View File

0
app/models/.gitkeep Normal file
View File

3
app/resolver.js Normal file
View File

@ -0,0 +1,3 @@
import Resolver from 'ember-resolver';
export default Resolver;

12
app/router.js Normal file
View File

@ -0,0 +1,12 @@
import EmberRouter from '@ember/routing/router';
import config from './config/environment';
const Router = EmberRouter.extend({
location: config.locationType,
rootURL: config.rootURL
});
Router.map(function() {
});
export default Router;

0
app/routes/.gitkeep Normal file
View File

0
app/styles/.gitkeep Normal file
View File

View File

@ -0,0 +1 @@
{{outlet}}

View File

51
config/environment.js Normal file
View File

@ -0,0 +1,51 @@
'use strict';
module.exports = function(environment) {
let ENV = {
modulePrefix: 'ember-quickstart',
environment,
rootURL: '/',
locationType: 'auto',
EmberENV: {
FEATURES: {
// Here you can enable experimental features on an ember canary build
// e.g. 'with-controller': true
},
EXTEND_PROTOTYPES: {
// Prevent Ember Data from overriding Date.parse.
Date: false
}
},
APP: {
// Here you can pass flags/options to your application instance
// when it is created
}
};
if (environment === 'development') {
// ENV.APP.LOG_RESOLVER = true;
// ENV.APP.LOG_ACTIVE_GENERATION = true;
// ENV.APP.LOG_TRANSITIONS = true;
// ENV.APP.LOG_TRANSITIONS_INTERNAL = true;
// ENV.APP.LOG_VIEW_LOOKUPS = true;
}
if (environment === 'test') {
// Testem prefers this...
ENV.locationType = 'none';
// keep test console output quieter
ENV.APP.LOG_ACTIVE_GENERATION = false;
ENV.APP.LOG_VIEW_LOOKUPS = false;
ENV.APP.rootElement = '#ember-testing';
ENV.APP.autoboot = false;
}
if (environment === 'production') {
// here you can enable a production-specific feature
}
return ENV;
};

View File

@ -0,0 +1,3 @@
{
"jquery-integration": true
}

18
config/targets.js Normal file
View File

@ -0,0 +1,18 @@
'use strict';
const browsers = [
'last 1 Chrome versions',
'last 1 Firefox versions',
'last 1 Safari versions'
];
const isCI = !!process.env.CI;
const isProduction = process.env.EMBER_ENV === 'production';
if (isCI || isProduction) {
browsers.push('ie 11');
}
module.exports = {
browsers
};