Thursday, April 25, 2024
HomeJavaScriptEmber 3.24 Launched

Ember 3.24 Launched


As we speak the Ember challenge is releasing model 3.24 of Ember.js, Ember Knowledge, and Ember CLI. This launch of Ember.js is an LTS (Lengthy Time period Help) candidate. LTS candidates prioritize stability over the addition of recent options, and have an prolonged help schedule.

This launch kicks off the three.25 beta cycle for all sub-projects. We encourage our group (particularly addon authors) to assist check these beta builds and report any bugs earlier than they’re printed as a last launch in six weeks’ time. The ember-try addon is an effective way to repeatedly check your tasks in opposition to the most recent Ember releases.

You may learn extra about our normal launch course of right here:


Ember.js

Ember.js is the core framework for constructing bold net purposes.

Adjustments in Ember.js 3.24

Ember.js 3.24 is an incremental, backwards suitable launch of Ember with bug fixes, efficiency enhancements, and minor deprecations.

Bug Fixes

Ember.js 3.24 launched 4 bug fixes.

  1. When the router service is injected (e.g. right into a element), the router service can robotically work in non-application checks. In different phrases, we now not have to name this.proprietor.setupRouter(). (#19080)
  2. When there isn’t any template related to a element class, the low-level API getComponentTemplate() now returns undefined as a substitute of null. The return worth of undefined is what had been specified within the Part Templates Colocation RFC. (#19253)
  3. In an Ember Engines app, the <LinkTo> element as soon as once more helps linking inside an engine. Please word, a repair was made doable via a breaking change within the personal implementation of <LinkTo>. Whenever you improve your app to v3.24 or above, it would be best to improve Ember Engines to at the very least ember-engines@0.8.9 (see launch notes right here for particulars). (#19223) ⚠️
  4. When a computed property has a dependent key that features @every, adopted by an aliased property, the computed property recomputes when the aliased property’s worth adjustments. (#19280)

Options

Ember.js 3.24 launched 3 options.

  1. When ember-page-title is put in, the blueprint for a route template creates a {{page-title}} helper invocation along with {{outlet}}. For extra info, please see RFC #645 and ember-page-title documentation. (#19224)
  2. The interface of DeprecationOptions, which will be handed to the deprecate() operate, requires the keys for and since to exist. For extra info, please see the Deprecation Staging RFC. (#19133)
  3. Glimmer VM, the rendering engine, has been upgraded to model 0.65.0. The improve features a bug repair and some upstreams. (#19258, #19261, #19267)

Deprecations

Ember.js 3.24 launched 4 deprecations.

  1. Going again to the interface of DeprecationOptions (see Options above), forgetting to move for or since will set off a deprecation message. (#19133)

  2. Ember.String.loc operate, @ember/string#loc operate, and {{loc}} helper have been deprecated in favor of a devoted localization answer like ember-intl. For extra info, please see the Deprecations Information. (#19211)

  3. Calling camelize, capitalize, classify, dasherize, decamelize, underscore, or w—these are Ember.String strategies—on a string is deprecated. As an alternative of calling the strategy on the string, you possibly can import the operate from @ember/string:

    // Earlier than
    let mascot = 'Empress Zoey';
    
    console.log(mascot.camelize());  // empressZoey
    
    // After
    import { camelize } from '@ember/string';
    
    let mascot = 'Empress Zoey';
    
    console.log(camelize(mascot));  // empressZoey
    

    For extra info, please see the Deprecations Information. (#19234)

  4. tryInvoke from @ember/utils module has been deprecated in favor of JavaScript’s non-obligatory chaining ?..

    // Earlier than
    import { tryInvoke } from '@ember/utils';
    
    let in the present day = new Date('01/07/2021');
    
    tryInvoke(in the present day, 'getTime');              // 1609974000000
    tryInvoke(in the present day, 'setFullYear', [2014]);  // 1389049200000
    tryInvoke(in the present day, 'noSuchMethod', [2014]); // undefined
    
    // After
    let in the present day = new Date('01/07/2021');
    
    in the present day.getTime?.();          // 1609974000000
    in the present day.setFullYear?.(2014);  // 1389049200000
    in the present day.noSuchMethod?.(2014); // undefined
    
    /*
      Word, `in the present day` is used within the context of `tryInvoke`.
      In consequence, we are able to assume that `in the present day` is an object
      and write `in the present day.getTime` as a substitute of `in the present day?.getTime`.
    
      The examples exist solely as an example the right way to refactor
      `tryInvoke`. Please do not write `in the present day.getTime?.()`
      in observe. :)
    */
    

    For extra info, please see the Deprecations Information.

Deprecations are added to Ember.js when an API might be eliminated at a later date. Every deprecation has an entry within the deprecation information describing the migration path to a extra secure API. Deprecated public APIs aren’t eliminated till a serious launch of the framework.

Think about using the ember-cli-deprecation-workflow addon if you need to improve your software with out instantly addressing deprecations.

Final however not least, Ember.js 3.24 eliminated a couple of function flags and an experimental API referred to as expandLocalLookup. For extra particulars on adjustments in Ember.js 3.24, please assessment the Ember.js 3.24.0 launch web page.


Ember Knowledge

Ember Knowledge is the official knowledge persistence library for Ember.js purposes.

Adjustments in Ember Knowledge 3.24

Bug Fixes

Ember Knowledge 3.24 launched 1 bug repair.

  1. In a manufacturing surroundings, an try to set one thing on a deleted report now not exhibits the worth within the error message. This was executed to stop leaking delicate knowledge. (#7370)

Options

Ember Knowledge 3.24 launched 0 options.

Deprecations

Ember Knowledge 3.24 launched 0 deprecations.

For extra particulars on adjustments in Ember Knowledge 3.24, please assessment the
Ember Knowledge 3.24.0 launch web page.


Ember CLI

Ember CLI is the command line interface for managing and packaging Ember.js purposes.

Upgrading Ember CLI

You might improve Ember CLI utilizing the ember-cli-update challenge:

npx ember-cli-update

This utility will enable you to to replace your app or addon to the most recent Ember CLI model. You’ll most likely encounter merge conflicts, during which the default conduct is to allow you to resolve conflicts by yourself. For extra info on the ember-cli-update challenge, see the GitHub README.

Whereas it is strongly recommended to maintain Ember CLI variations in sync with Ember and Ember Knowledge, this isn’t required. After updating ember-cli, you possibly can maintain your present model(s) of Ember or Ember Knowledge by enhancing bundle.json to revert the adjustments to the traces containing ember-source and ember-data.

Adjustments in Ember CLI 3.24

Bug Fixes

Ember CLI 3.24 launched 1 bug repair.

  1. When Embroider v2 addons are current, forestall forming a cycle within the construct course of. (#9402)

Options

Ember CLI 3.24 upgraded the packages which can be current within the bundle.json blueprint to their newest model. There are 4 notable adjustments to the bundle.json blueprint:

  1. ember-page-title has been added to the blueprint. For extra info, please see RFC #645 and ember-page-title documentation. (#9372, #9382)
  2. ember-qunit has been upgraded to v5 (a serious model change). Following the migration information, the bundle.json blueprint consists of @ember/test-helpers and qunit. The blueprints for checks/index.html and checks/test-helper.js have been up to date as nicely. (#9340, #9371)
  3. eslint-plugin-ember has been upgraded to v10 (a serious model change), which promoted octane guidelines to really useful and enabled a number of extra guidelines as really useful. To study extra about these linting guidelines, please examine the eslint-plugin-ember documentation. (#9403)
  4. prettier (together with eslint-config-prettier and eslint-plugin-prettier) has been added to the blueprint. To study extra, please see RFC #628 and Prettier documentation. (#9391, #9407, #9410)

Deprecations

Ember CLI 3.24 launched 0 deprecations.

For extra particulars on the adjustments in Ember CLI 3.24 and detailed improve
directions, please assessment the Ember CLI 3.24.0 launch web page.

Thank You!

As a community-driven open-source challenge with an bold scope, every of those releases serves as a reminder that the Ember challenge wouldn’t have been doable with out your continued help. We’re extraordinarily grateful to our contributors for his or her efforts.

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments