ember didn't want to ember, so now it embers again
This commit is contained in:
parent
5a82179df6
commit
876c7a2b73
56 changed files with 1715 additions and 7649 deletions
|
@ -2,6 +2,7 @@
|
|||
/blueprints/*/files/
|
||||
|
||||
# compiled output
|
||||
/declarations/
|
||||
/dist/
|
||||
|
||||
# misc
|
56
frontend-reactive/README.md
Normal file
56
frontend-reactive/README.md
Normal file
|
@ -0,0 +1,56 @@
|
|||
# frontend-reactive
|
||||
|
||||
This README outlines the details of collaborating on this Ember application.
|
||||
A short introduction of this app could easily go here.
|
||||
|
||||
## Prerequisites
|
||||
|
||||
You will need the following things properly installed on your computer.
|
||||
|
||||
- [Git](https://git-scm.com/)
|
||||
- [Node.js](https://nodejs.org/) (with npm)
|
||||
- [Ember CLI](https://cli.emberjs.com/release/)
|
||||
- [Google Chrome](https://google.com/chrome/)
|
||||
|
||||
## Installation
|
||||
|
||||
- `git clone <repository-url>` this repository
|
||||
- `cd frontend-reactive`
|
||||
- `npm install`
|
||||
|
||||
## Running / Development
|
||||
|
||||
- `npm run start`
|
||||
- Visit your app at [http://localhost:4200](http://localhost:4200).
|
||||
- Visit your tests at [http://localhost:4200/tests](http://localhost:4200/tests).
|
||||
|
||||
### Code Generators
|
||||
|
||||
Make use of the many generators for code, try `ember help generate` for more details
|
||||
|
||||
### Running Tests
|
||||
|
||||
- `npm run test`
|
||||
- `npm run test:ember -- --server`
|
||||
|
||||
### Linting
|
||||
|
||||
- `npm run lint`
|
||||
- `npm run lint:fix`
|
||||
|
||||
### Building
|
||||
|
||||
- `npm exec ember build` (development)
|
||||
- `npm run build` (production)
|
||||
|
||||
### Deploying
|
||||
|
||||
Specify what it takes to deploy your app.
|
||||
|
||||
## Further Reading / Useful Links
|
||||
|
||||
- [ember.js](https://emberjs.com/)
|
||||
- [ember-cli](https://cli.emberjs.com/release/)
|
||||
- Development Browser Extensions
|
||||
- [ember inspector for chrome](https://chrome.google.com/webstore/detail/ember-inspector/bmdblncegkenkacieihfhpjfppoconhi)
|
||||
- [ember inspector for firefox](https://addons.mozilla.org/en-US/firefox/addon/ember-inspector/)
|
|
@ -1,7 +1,7 @@
|
|||
import Application from '@ember/application';
|
||||
import Resolver from 'ember-resolver';
|
||||
import loadInitializers from 'ember-load-initializers';
|
||||
import config from 'frontend-src/config/environment';
|
||||
import config from 'frontend-reactive/config/environment';
|
||||
|
||||
export default class App extends Application {
|
||||
modulePrefix = config.modulePrefix;
|
4
frontend-reactive/app/components/timeline/note.hbs
Normal file
4
frontend-reactive/app/components/timeline/note.hbs
Normal file
|
@ -0,0 +1,4 @@
|
|||
<div>
|
||||
<h3>{{@username}}</h3>
|
||||
<p>{{@content}}</p>
|
||||
</div>
|
|
@ -1,6 +1,6 @@
|
|||
/**
|
||||
* Type declarations for
|
||||
* import config from 'frontend-src/config/environment'
|
||||
* import config from 'frontend-reactive/config/environment'
|
||||
*/
|
||||
declare const config: {
|
||||
environment: string;
|
|
@ -2,14 +2,14 @@
|
|||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>FrontendSrc</title>
|
||||
<title>FrontendReactive</title>
|
||||
<meta name="description" content="">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
{{content-for "head"}}
|
||||
|
||||
<link integrity="" rel="stylesheet" href="{{rootURL}}assets/vendor.css">
|
||||
<link integrity="" rel="stylesheet" href="{{rootURL}}assets/frontend-src.css">
|
||||
<link integrity="" rel="stylesheet" href="{{rootURL}}assets/frontend-reactive.css">
|
||||
|
||||
{{content-for "head-footer"}}
|
||||
</head>
|
||||
|
@ -17,7 +17,7 @@
|
|||
{{content-for "body"}}
|
||||
|
||||
<script src="{{rootURL}}assets/vendor.js"></script>
|
||||
<script src="{{rootURL}}assets/frontend-src.js"></script>
|
||||
<script src="{{rootURL}}assets/frontend-reactive.js"></script>
|
||||
|
||||
{{content-for "body-footer"}}
|
||||
</body>
|
|
@ -1,5 +1,5 @@
|
|||
import EmberRouter from '@ember/routing/router';
|
||||
import config from 'frontend-src/config/environment';
|
||||
import config from 'frontend-reactive/config/environment';
|
||||
|
||||
export default class Router extends EmberRouter {
|
||||
location = config.locationType;
|
||||
|
@ -7,8 +7,5 @@ export default class Router extends EmberRouter {
|
|||
}
|
||||
|
||||
Router.map(function () {
|
||||
this.route('notes', function () {
|
||||
this.route('note', { path: '/:note_id' });
|
||||
this.route('index', { path: '/' });
|
||||
});
|
||||
// Add route declarations here
|
||||
});
|
4
frontend-reactive/app/templates/application.hbs
Normal file
4
frontend-reactive/app/templates/application.hbs
Normal file
|
@ -0,0 +1,4 @@
|
|||
{{page-title "FrontendReactive"}}
|
||||
|
||||
{{outlet}}
|
||||
<Timeline::Note @username="bob" @content="Hello world" />
|
|
@ -3,7 +3,7 @@
|
|||
"packages": [
|
||||
{
|
||||
"name": "ember-cli",
|
||||
"version": "5.7.0",
|
||||
"version": "5.11.0",
|
||||
"blueprints": [
|
||||
{
|
||||
"name": "app",
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
module.exports = function (environment) {
|
||||
const ENV = {
|
||||
modulePrefix: 'frontend-src',
|
||||
modulePrefix: 'frontend-reactive',
|
||||
environment,
|
||||
rootURL: '/',
|
||||
locationType: 'history',
|
File diff suppressed because it is too large
Load diff
|
@ -1,8 +1,8 @@
|
|||
{
|
||||
"name": "frontend-src",
|
||||
"name": "frontend-reactive",
|
||||
"version": "0.0.0",
|
||||
"private": true,
|
||||
"description": "Small description for frontend-src goes here",
|
||||
"description": "Small description for frontend-reactive goes here",
|
||||
"repository": "",
|
||||
"license": "EUPL-1.2",
|
||||
"author": "",
|
||||
|
@ -26,15 +26,15 @@
|
|||
"test:ember": "ember test"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.24.0",
|
||||
"@babel/core": "^7.25.2",
|
||||
"@ember/optional-features": "^2.1.0",
|
||||
"@ember/string": "^3.1.1",
|
||||
"@ember/test-helpers": "^3.3.0",
|
||||
"@ember/test-helpers": "^3.3.1",
|
||||
"@glimmer/component": "^1.1.2",
|
||||
"@glimmer/tracking": "^1.1.2",
|
||||
"@glint/environment-ember-loose": "^1.3.0",
|
||||
"@glint/template": "^1.3.0",
|
||||
"@tsconfig/ember": "^3.0.4",
|
||||
"@glint/environment-ember-loose": "^1.4.0",
|
||||
"@glint/template": "^1.4.0",
|
||||
"@tsconfig/ember": "^3.0.8",
|
||||
"@types/ember": "^4.0.11",
|
||||
"@types/ember-data": "^4.4.16",
|
||||
"@types/ember-data__adapter": "^4.0.6",
|
||||
|
@ -49,7 +49,7 @@
|
|||
"@types/ember__destroyable": "^4.0.5",
|
||||
"@types/ember__engine": "^4.0.11",
|
||||
"@types/ember__error": "^4.0.6",
|
||||
"@types/ember__helper": "^4.0.7",
|
||||
"@types/ember__helper": "^4.0.8",
|
||||
"@types/ember__modifier": "^4.0.9",
|
||||
"@types/ember__object": "^4.0.12",
|
||||
"@types/ember__owner": "^4.0.9",
|
||||
|
@ -67,8 +67,8 @@
|
|||
"@typescript-eslint/parser": "^6.21.0",
|
||||
"broccoli-asset-rev": "^3.0.0",
|
||||
"concurrently": "^8.2.2",
|
||||
"ember-auto-import": "^2.7.2",
|
||||
"ember-cli": "~5.7.0",
|
||||
"ember-auto-import": "^2.7.4",
|
||||
"ember-cli": "~5.11.0",
|
||||
"ember-cli-app-version": "^6.0.1",
|
||||
"ember-cli-babel": "^8.2.0",
|
||||
"ember-cli-clean-css": "^3.0.0",
|
||||
|
@ -77,32 +77,32 @@
|
|||
"ember-cli-inject-live-reload": "^2.1.0",
|
||||
"ember-cli-sri": "^2.1.1",
|
||||
"ember-cli-terser": "^4.0.2",
|
||||
"ember-data": "~5.3.3",
|
||||
"ember-data": "~5.3.8",
|
||||
"ember-fetch": "^8.1.2",
|
||||
"ember-load-initializers": "^2.1.2",
|
||||
"ember-modifier": "^4.1.0",
|
||||
"ember-page-title": "^8.2.2",
|
||||
"ember-qunit": "^8.0.2",
|
||||
"ember-modifier": "^4.2.0",
|
||||
"ember-page-title": "^8.2.3",
|
||||
"ember-qunit": "^8.1.0",
|
||||
"ember-resolver": "^11.0.1",
|
||||
"ember-source": "~5.7.0",
|
||||
"ember-source": "~5.11.0",
|
||||
"ember-template-lint": "^5.13.0",
|
||||
"ember-welcome-page": "^7.0.2",
|
||||
"eslint": "^8.57.0",
|
||||
"eslint-config-prettier": "^9.1.0",
|
||||
"eslint-plugin-ember": "^11.12.0",
|
||||
"eslint-plugin-n": "^16.6.2",
|
||||
"eslint-plugin-prettier": "^5.1.3",
|
||||
"eslint-plugin-prettier": "^5.2.1",
|
||||
"eslint-plugin-qunit": "^8.1.1",
|
||||
"loader.js": "^4.7.0",
|
||||
"prettier": "^3.2.5",
|
||||
"qunit": "^2.20.1",
|
||||
"prettier": "^3.3.3",
|
||||
"qunit": "^2.22.0",
|
||||
"qunit-dom": "^2.0.0",
|
||||
"stylelint": "^15.11.0",
|
||||
"stylelint-config-standard": "^34.0.0",
|
||||
"stylelint-prettier": "^4.1.0",
|
||||
"tracked-built-ins": "^3.3.0",
|
||||
"typescript": "^5.3.3",
|
||||
"webpack": "^5.90.3"
|
||||
"typescript": "^5.5.4",
|
||||
"webpack": "^5.93.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 18"
|
|
@ -24,7 +24,7 @@ function setupApplicationTest(hooks: NestedHooks, options?: SetupTestOptions) {
|
|||
// This is also a good place to call test setup functions coming
|
||||
// from other addons:
|
||||
//
|
||||
// setupIntl(hooks); // ember-intl
|
||||
// setupIntl(hooks, 'en-us'); // ember-intl
|
||||
// setupMirage(hooks); // ember-cli-mirage
|
||||
}
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>FrontendSrc Tests</title>
|
||||
<title>FrontendReactive Tests</title>
|
||||
<meta name="description" content="">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
|
@ -10,7 +10,7 @@
|
|||
{{content-for "test-head"}}
|
||||
|
||||
<link rel="stylesheet" href="{{rootURL}}assets/vendor.css">
|
||||
<link rel="stylesheet" href="{{rootURL}}assets/frontend-src.css">
|
||||
<link rel="stylesheet" href="{{rootURL}}assets/frontend-reactive.css">
|
||||
<link rel="stylesheet" href="{{rootURL}}assets/test-support.css">
|
||||
|
||||
{{content-for "head-footer"}}
|
||||
|
@ -30,7 +30,7 @@
|
|||
<script src="/testem.js" integrity="" data-embroider-ignore></script>
|
||||
<script src="{{rootURL}}assets/vendor.js"></script>
|
||||
<script src="{{rootURL}}assets/test-support.js"></script>
|
||||
<script src="{{rootURL}}assets/frontend-src.js"></script>
|
||||
<script src="{{rootURL}}assets/frontend-reactive.js"></script>
|
||||
<script src="{{rootURL}}assets/tests.js"></script>
|
||||
|
||||
{{content-for "body-footer"}}
|
|
@ -1,24 +1,24 @@
|
|||
import { module, test } from 'qunit';
|
||||
import { setupRenderingTest } from 'frontend-src/tests/helpers';
|
||||
import { setupRenderingTest } from 'frontend-reactive/tests/helpers';
|
||||
import { render } from '@ember/test-helpers';
|
||||
import { hbs } from 'ember-cli-htmlbars';
|
||||
|
||||
module('Integration | Component | note', function (hooks) {
|
||||
module('Integration | Component | timeline/note', function (hooks) {
|
||||
setupRenderingTest(hooks);
|
||||
|
||||
test('it renders', async function (assert) {
|
||||
// Set any properties with this.set('myProperty', 'value');
|
||||
// Handle any actions with this.set('myAction', function(val) { ... });
|
||||
|
||||
await render(hbs`<Note />`);
|
||||
await render(hbs`<Timeline::Note />`);
|
||||
|
||||
assert.dom().hasText('');
|
||||
|
||||
// Template block usage:
|
||||
await render(hbs`
|
||||
<Note>
|
||||
<Timeline::Note>
|
||||
template block text
|
||||
</Note>
|
||||
</Timeline::Note>
|
||||
`);
|
||||
|
||||
assert.dom().hasText('template block text');
|
|
@ -1,5 +1,5 @@
|
|||
import Application from 'frontend-src/app';
|
||||
import config from 'frontend-src/config/environment';
|
||||
import Application from 'frontend-reactive/app';
|
||||
import config from 'frontend-reactive/config/environment';
|
||||
import * as QUnit from 'qunit';
|
||||
import { setApplication } from '@ember/test-helpers';
|
||||
import { setup } from 'qunit-dom';
|
|
@ -6,8 +6,8 @@
|
|||
// work with TypeScript.
|
||||
"baseUrl": ".",
|
||||
"paths": {
|
||||
"frontend-src/tests/*": ["tests/*"],
|
||||
"frontend-src/*": ["app/*"],
|
||||
"frontend-reactive/tests/*": ["tests/*"],
|
||||
"frontend-reactive/*": ["app/*"],
|
||||
"*": ["types/*"]
|
||||
}
|
||||
}
|
|
@ -1,56 +0,0 @@
|
|||
# frontend-src
|
||||
|
||||
This README outlines the details of collaborating on this Ember application.
|
||||
A short introduction of this app could easily go here.
|
||||
|
||||
## Prerequisites
|
||||
|
||||
You will need the following things properly installed on your computer.
|
||||
|
||||
* [Git](https://git-scm.com/)
|
||||
* [Node.js](https://nodejs.org/) (with npm)
|
||||
* [Ember CLI](https://cli.emberjs.com/release/)
|
||||
* [Google Chrome](https://google.com/chrome/)
|
||||
|
||||
## Installation
|
||||
|
||||
* `git clone <repository-url>` this repository
|
||||
* `cd frontend-src`
|
||||
* `npm install`
|
||||
|
||||
## Running / Development
|
||||
|
||||
* `npm run start`
|
||||
* Visit your app at [http://localhost:4200](http://localhost:4200).
|
||||
* Visit your tests at [http://localhost:4200/tests](http://localhost:4200/tests).
|
||||
|
||||
### Code Generators
|
||||
|
||||
Make use of the many generators for code, try `ember help generate` for more details
|
||||
|
||||
### Running Tests
|
||||
|
||||
* `npm run test`
|
||||
* `npm run test:ember -- --server`
|
||||
|
||||
### Linting
|
||||
|
||||
* `npm run lint`
|
||||
* `npm run lint:fix`
|
||||
|
||||
### Building
|
||||
|
||||
* `npm exec ember build` (development)
|
||||
* `npm run build` (production)
|
||||
|
||||
### Deploying
|
||||
|
||||
Specify what it takes to deploy your app.
|
||||
|
||||
## Further Reading / Useful Links
|
||||
|
||||
* [ember.js](https://emberjs.com/)
|
||||
* [ember-cli](https://cli.emberjs.com/release/)
|
||||
* Development Browser Extensions
|
||||
* [ember inspector for chrome](https://chrome.google.com/webstore/detail/ember-inspector/bmdblncegkenkacieihfhpjfppoconhi)
|
||||
* [ember inspector for firefox](https://addons.mozilla.org/en-US/firefox/addon/ember-inspector/)
|
|
@ -1 +0,0 @@
|
|||
{{yield}}
|
|
@ -1,14 +0,0 @@
|
|||
import Component from '@glimmer/component';
|
||||
|
||||
export interface NoteSignature {
|
||||
// The arguments accepted by the component
|
||||
Args: {};
|
||||
// Any blocks yielded by the component
|
||||
Blocks: {
|
||||
default: [];
|
||||
};
|
||||
// The element to which `...attributes` is applied in the component template
|
||||
Element: null;
|
||||
}
|
||||
|
||||
export default class NoteComponent extends Component<NoteSignature> {}
|
|
@ -1,3 +0,0 @@
|
|||
import Route from '@ember/routing/route';
|
||||
|
||||
export default class NotesRoute extends Route {}
|
|
@ -1,3 +0,0 @@
|
|||
import Route from '@ember/routing/route';
|
||||
|
||||
export default class NotesIndexRoute extends Route {}
|
|
@ -1,9 +0,0 @@
|
|||
import Route from '@ember/routing/route';
|
||||
import type Transition from '@ember/routing/transition';
|
||||
|
||||
export default class NotesNoteRoute extends Route {
|
||||
model(params: any, transition: Transition) {
|
||||
console.log(params);
|
||||
return { title: params.note_id };
|
||||
}
|
||||
}
|
|
@ -1,4 +0,0 @@
|
|||
{{page-title "FrontendSrc"}}
|
||||
|
||||
<h1>Home page</h1>
|
||||
{{outlet}}
|
|
@ -1,3 +0,0 @@
|
|||
{{page-title "Notes"}}
|
||||
<h2>Note wrapper</h2>
|
||||
{{outlet}}
|
|
@ -1,4 +0,0 @@
|
|||
{{page-title "Index"}}
|
||||
|
||||
<h3>Note index</h3>
|
||||
{{outlet}}
|
|
@ -1,4 +0,0 @@
|
|||
{{page-title "Note"}}
|
||||
|
||||
<h3>Note {{@model.title}}</h3>
|
||||
{{outlet}}
|
|
@ -1,11 +0,0 @@
|
|||
import { module, test } from 'qunit';
|
||||
import { setupTest } from 'frontend-src/tests/helpers';
|
||||
|
||||
module('Unit | Route | notes', function (hooks) {
|
||||
setupTest(hooks);
|
||||
|
||||
test('it exists', function (assert) {
|
||||
const route = this.owner.lookup('route:notes');
|
||||
assert.ok(route);
|
||||
});
|
||||
});
|
|
@ -1,11 +0,0 @@
|
|||
import { module, test } from 'qunit';
|
||||
import { setupTest } from 'frontend-src/tests/helpers';
|
||||
|
||||
module('Unit | Route | notes/index', function (hooks) {
|
||||
setupTest(hooks);
|
||||
|
||||
test('it exists', function (assert) {
|
||||
const route = this.owner.lookup('route:notes/index');
|
||||
assert.ok(route);
|
||||
});
|
||||
});
|
|
@ -1,11 +0,0 @@
|
|||
import { module, test } from 'qunit';
|
||||
import { setupTest } from 'frontend-src/tests/helpers';
|
||||
|
||||
module('Unit | Route | notes/note', function (hooks) {
|
||||
setupTest(hooks);
|
||||
|
||||
test('it exists', function (assert) {
|
||||
const route = this.owner.lookup('route:notes/note');
|
||||
assert.ok(route);
|
||||
});
|
||||
});
|
Loading…
Reference in a new issue