Questions tagged [ember.js]
Ember.js is a component-service application framework written in JavaScript. Consider making your question easier to answer by using the preconfigured templates mentioned in this tag's wiki. (Always specify version of ember used when describing your issue)
23,694
questions
0
votes
0answers
20 views
Does ember-collapsible-panel have Octane support?
I have upgraded ember app 2.15 to 3.16 version. I am using ember-collapsible-panel@latest version. After upgrading to Octane version, ember-collapsible-panel does not seem to be working properly. I'm ...
0
votes
0answers
14 views
Google Picker with Ember front end + server side authentication
Scene:
I'm building with Ember as my front end (simple auth)
Authentication is server side running on Node. Bearer, refresh token etc.
I've already integrated Classroom API & Drive API - ...
0
votes
0answers
16 views
How to know when Ember query params have loaded without using Route?
I am working on a 3rd party Search component that filters based on query params in the URL.
If no query params are provided, a default search is made on init().
I am having an issue because at the ...
1
vote
1answer
28 views
Is there a way to tell if a yielded component's has-block is empty?
I am trying to make a contextual component that can provide a default header when one is not passed in the yielded block. Normally, I could use the has-block helper to tell if a component has block ...
0
votes
0answers
18 views
EmberJS + TailwindCSS: slow website in production
I'm testing tailwind and ember for a musical website. I experience several bugs:
in dev server, all links start with a capital letter; on some links the capital letter disappears (live demo, artists)....
1
vote
0answers
18 views
Storybook adds a period after http: to all links and scripts in preview-head.html, how to remove this
I am using Storybookjs with Emberjs. When it generates the preview-head.html file it adds all the links and scripts in my current index.html file but adds a period after the : causing them to not work....
-1
votes
0answers
14 views
How to use components and controllers in ember.js [closed]
I am new to ember.js and there is a practice challenge on an app https://github.com/tunapanda/frontend-ember-challenge
The challenges are:
Add an action to the Single Task Component that sends a task
...
0
votes
1answer
21 views
Handlebars if statement issue
{{#each this.data.roles as |role|}}
{{#if (eq role.name ( 'moderator' 'organizer'))}}
<div class="item">
{{role.name}}
</div>
...
-1
votes
0answers
30 views
How do I find the xpath of a dynamic ember module - code doesn't appear in “inspect”
I'm using Selenium to automatically export data from LinkedIn. My code works up until I click the export button in the analytics section, then I'm stuck because I can't find the xpath or id of the ...
1
vote
1answer
34 views
Can we use Ember.js to build a static website?
Can we use Ember.js to build a static website? We are going to store the website in AWS S3.
Kind regards
0
votes
0answers
24 views
Ember add-on random tests fail with "Can not call `.lookup` after the owner has been destroyed” after updating ember and dependencies
I updated my add-on’s dependencies, and ember version to use octane (following ember guide). The add-on works correctly as it did before, but not the tests. A single random test (not always the same ...
0
votes
0answers
20 views
How to render ember template for a nested dynamic route?
js`, I have declared some nested routes like this:
Router.map(function() {
this.route('index', { path: '/' })
this.route('orders', function() {
this.route('details', { path: '/:order_id' });
...
0
votes
0answers
28 views
CssSyntaxError @fullcalendar/common/main.css Unknown word
I'm using Ember 3.19 and ember-auto-import@^1.5.3 with webpack config to build @fullcalendar/core@^5.5.0 as a module into my Ember app.
I run into this error during build, not certain what the issue ...
0
votes
1answer
18 views
Ember: this.router.refresh() throws error in ember octane
This is the below code I am using while doing refresh the route
export default class MyController extend Controller {
@service router;
@action refresh() {
this.router.refresh()
}
...
0
votes
1answer
41 views
Error “str.replace is not a function” when using store.queryRecord with Ember Octane
I'm following an Embercasts course (Ember + Rails). For the screencasts, they used Ember 3.0, but I'm using Octane.
In one video, a custom service is implemented. This is what my version looks like:
...
1
vote
0answers
28 views
Ember Data JSON API - How to make a PATCH request using a related links URL
Ember version: 3.23
Ember Data: 3.23
I want to patch a relationship by making a request to the URL provided in the links object in the resources relationships:
{
"type": "appointments&...
1
vote
1answer
27 views
What is the correct way to convert observer to octane version of ember?
I was trying to convert all my ember-component into OCTANE version. But I got a bigger doubt. How can I convert the observer code into an OCTANE version? For example,
parent.hbs
<Child @value={{...
0
votes
1answer
18 views
Update model hook value after button click and taking new value from input text
Newcomer here,
async model() {
let response = await fetch('http://api.openweathermap.org/data/2.5/weather?q=London&units=metric&appid=[APIKeyPlaceholder]);
var data = await response.json();
...
0
votes
0answers
29 views
How to test Ember computed properties that have no arguments/property dependencies?
You can find my source & test code below. I am testing the custom formHasSuccess() function, which has no arguments (or property dependencies). Using hasCorrectLength() & ...
0
votes
1answer
27 views
Ember-Octane: Obj can't be observed in template while updated?
Most of you thought this is a weired question. Me too...
So, here is a controller file I'm having
application.js
export default class Application extends Controller.extend(someMixin) {
@tracked ...
0
votes
1answer
32 views
How to listen parent component value change in child component ember octane?
This is my code
parent.hbs
<ChildComp
@value={{this.changes}}
/>
parent.js
export class ParentComponet extends Component {
@tracked this.changes = [1,2,3]
@action addChanges() {
...
0
votes
0answers
16 views
What causing this issue when capturing screen shot with PIXI JS
I have used PIXI JS to capture screen and save as screenshots. It works fine on some screens and it gives and error on another screen. Anyone have an idea which causing this error?
0
votes
3answers
43 views
How do I go about stubbing a Task in Ember.js?
I am using Sinon with Ember.js Concurrency Tasks and am trying to stub the task in a test.
The code looks something like this:
component .ts file:
import Component from '@glimmer/component';
import { ...
0
votes
1answer
29 views
How to pass conditional string to ember component attribute using concat?
What is the correct way to pass the conditional string when assigning the component's attribute using ember concat() method?
Consider the following
{{#my-compontent class=(concat (dasherize model.name)...
0
votes
0answers
26 views
Ember.js - Parsing error: Unexpected token, expected “;” in config/environment.d.ts(.js)
I see that error/warning in every build or run.
...lisweb_frontend/app/config/environment.d.ts
10:9 error Parsing error: Unexpected token, expected ";"
8 | * since different ember ...
0
votes
1answer
82 views
Ember component is not re-rendering on change of @tracked variable
My UserTag component is only re-rendering on page refresh. I expect it to refresh when action saveRoles(updatedUserRoles) is used, since it depends on an @tracked variable.
UserRoles is a component ...
0
votes
0answers
16 views
Ember.js with Yarn: Cannot find module './_baseUniq' (Works with NPM)
Recently, I'm get that error above when using Ember.js project with Yarn, not occurred with NPM.
The error:
Cannot find module './_baseUniq'
Require stack:
- /mnt/82eb80d7-628c-41a3-b046-c40ab727aaaf/...
2
votes
1answer
48 views
How to detect if included relationship is loading
Please see related twiddle https://ember-twiddle.com/e3872f1410e0d844b6d6c6bc9a2c9dc1
// models/parent.js
export default class extends Model {
@attr('string') name;
@hasMany('child') children;
}
/...
0
votes
0answers
25 views
How to creating an app with Laravel + EmberJS
I need to create an app using EmberJS 2.18 for the frontend and Laravel ^6.0 for the backend. I found a guide (here: https://culttt.com/2015/04/06/getting-started-with-laravel-and-ember/) but it's 5 ...
1
vote
0answers
44 views
Reading a Json Array from a snapshot to ember html page with no Jquery
I set a bookmarks and favorites page of movies to a firebase at a movie profile page. Now I am trying to grab the information from only the ones that are bookmarked, grab the information (movieIds, ...
1
vote
0answers
24 views
Security issues with having an array of allowed origins for iFrame?
Currently I have a couple environments of the same URL that should be allowed to listen to the postMessage and the issue I have is that these URLs are exposed in the index.html and was wondering is ...
0
votes
1answer
43 views
Interact.js - dragging single div “jumping around” in Ember
I'm using Ember, and I'm trying to setup a simple draggable div example using the interact.js library but I'm having some issues.
I'm aware that the library DOES NOT modify the DOM and you need to do ...
0
votes
0answers
22 views
EmberJS 3.19 performance issues with large amount of data
So I'm currently trying to debug some major performance issues we're having with our app. Once some more data is loaded (~1000 in the store, ~30 rendered) the app tends to get slowed down by a lot. ...
0
votes
5answers
65 views
Click on ember.js enabled element using Selenium
I am trying to click on the following button on a linkedin page using selenium:
<button id="ember607" class="share-actions__primary-action artdeco-button artdeco-button--2 artdeco-...
3
votes
1answer
47 views
ember js access environment from ember-cli-build in the vendor file
In my ember-cli-build.js file I'm importing a vendor library called new-relic by using app.import('vendor/new-relic.js'), I would like to pass a parameter called env to the new-relic vendor file and ...
1
vote
1answer
41 views
Getting properties of ember component from ember component-class
I have been trying to get the value of a property of a component from action from its class. My main goal is to relate two objects: the "auction" passed into my component (shown in the code ...
0
votes
1answer
48 views
Map update periodically in forestadmin using leaflet
I am using map to show riders while driving. Map is showing location as a marker on Map.
But my map is not updating after data updated in mongodb. I am using forestadmin and node js. In forestadmin, I ...
0
votes
1answer
19 views
How to use ember-2-legacy?
We have the post in the documentation for Ember 2.16 about addition deprecation ember-2-legacy:
Ember 2 Legacy
until: 3.4
id: ember-2-legacy
Ember provides ember-2-legacy which is an addon to help ...
0
votes
1answer
44 views
Ember required component arguments
How can I require a parameter in an ember component.
E.g.:
class MyComponent extends Component {
get my_value() {
return this.args.my_argument + 1
}
}
I want the component to throw an error ...
1
vote
1answer
49 views
EmberJS: Injecting owner to native class from component
The thing i'm trying to do, is to inject owner to my JS native class in Ember(3.15.0).
It looks something like this:
component.ts
export default class ClassOne extends Component {
constructor(...
1
vote
1answer
34 views
Timezone sensitive date comparisons in Javascript
I'm determining the difference between two calendar dates in Javascript in an Ember app. I'm currently using date-fns's differenceInCalendarDays.
Now that mostly provides the desired results, the only ...
1
vote
0answers
27 views
Ember JS 3.20 app with SailsJS 0.12.x backend and websocket connection
I am using sails 0.12.14 version back-end with EmberJS 3.20 front-end. I am currently dealing with a websocket connection problem in production.
Using "sails.io.js": "^1.1.0", &...
1
vote
1answer
33 views
How trigger a function inside component whenever arguments change in Emnber octane
so i have a parent in controller like this
import Controller from '@ember/controller';
export default class IndexController extends Controller {
@service firebaseApp;
@service fastboot;
@tracked user ...
2
votes
2answers
51 views
How to click on the ember.js enabled button using Selenium and Python
I have been trying to make this clickable and I just cannot understand what I am doing wrong.
I am also trying to induce webdriverwait, so that it is clicked when it appears.
This is my code so far:
...
0
votes
1answer
69 views
ember hasDirtyAttributes do not work with object (json)
I have a model:
export default Model.extend({
title: attr('string'),
attributes: attr('jsonb')
});
Where attributes is a custom json filed stored as jsonb in Postgres.
let say:
{
"name":...
0
votes
1answer
29 views
Error: 'ReferenceError: pauseTest is not defined' in integration tests with moduleForComponent syntax
The pauseTest() function from ember-qunit does not work as expected in Integration tests with the old syntax
import { moduleForComponent, test } from 'ember-qunit';
import hbs from 'htmlbars-inline-...
0
votes
1answer
9 views
After bump ember-data from 2.13 to 2.14 the request payload not contain hasMany relations when the relation model had empty relation
with ActiveModelSerializer usage after the ember-data upgrade, the values of has_many case on the request payload had changed when the model has no records by relation, for example:
// app/models/user....
0
votes
1answer
16 views
Is it necessary to migrate from ember-data/active-model-adapter to DS.JSONAPISerializer for ember 3?
Documentation for DS.ActiveModelAdapter is exists only for 1.13 (for 2 - 404:
https://api.emberjs.com/ember-data/1.13/classes/DS.ActiveModelAdapter
So, it looks like it's moved out from DS:
https://...
0
votes
0answers
22 views
Command like “ember s” gets stuck and not loading
I’ve been following Getting started: https://guides.emberjs.com/release/getting-started/quick-start/.
I did:
npm install -g ember-cli
ember new ember-quickstart
cd ember-quickstart
ember serve
After ...
0
votes
2answers
36 views
How do I update data in the service store in Ember?
I created a service where I declared the store:
store.js:
import Service from '@ember/service';
export default class StoreService extends Service {
store = {
lang: 'EN'
}
}
I also got access ...