Emblem 0.5.0

February 27th, 2015

Emblem is an alternative Ember.js template syntax created by Alex Matchneer @machty. Due to some internal compiling to the Handlebars AST (abstract syntax tree), keeping Emblem up to date and backward compatible has been difficult. When Emblem was initially authored, the Handlebars AST was pitched as a stable API to write other applications against. This has not held up over time.

There is another path. With sponsorship from our friends at Vestorly and guidance from Alex, 201 Created set aside a few days to rewrite Emblem as a template printer. As a “printer”, Emblem no longer outputs compiled and executable templates. Instead, it generates Ember template strings. Since Ember template syntax is protected by semantic versioning, Emblem is now compatible with many versions of Ember regardless of the template engine (Handlebars 1.3, Handlebars 2.0, HTMLBars).

For example, an Emblem template used with Ember 1.10 will be built in these steps. First, the template:

1
2
3
4
5
/ app/templates/index.emblem
h1 Howdy Friend!

div
  marquee-banner | Emblem makes life easy!

Is compiled into an Ember template:

1
2
{{! app/templates/index.hbs }}
<h1>Howdy Friend!</h1><div>{{#marquee-banner}}Emblem makes life easy!{{/marquee-banner}}</div>

This raw template is compiled by the build pipeline into an executable template. The printing step isolates Emblem from the Ember template compile step, allowing that to be based on whatever version of Ember the application uses.

We also gain a great new feature from this conversion: Developers considering Emblem, but intimidated by the risk of “lock-in” can rest easy. With a little bit of additional work into pretty-printing Emblem should soon have an easy off ramp for those wanting to return to a more traditional syntax: Just save the Ember templates!

Several issues remain open after this spike. We’ve opened a 0.5.1 Milestone to track them.

We’ve had a fascinating time implementing the new printer and we’re looking forward to sharing more details in a forthcoming blog post.

Upgrading to Emblem 0.5.0 with Ember-CLI

If you currently use Emblem and want to upgrade (say, for 1.10 support and HTMLBars? ;-), follow these steps:

You can quickly install the printer with:


ember install:addon ember-cli-emblem-hbs-printer

That’s it! Your Emblem templates will be compiled like any other .hbs file in your codebase.

A demo application can be found at 201-created/ember-cli-emblem-example.

Many thanks to Vestorly for their sponsorship of 201 Created’s time on Emblem. If you’re a frontend developer looking for a new opportunity, Vestorly is tackling new and interesting Ember.js challenges every day. Check them out.

Ember Community Survey, 2015

February 4th, 2015

The 2015 Community Survey closed on February 20th. Thank you for participating!

Calling all Ember users!

In 2014 Ember.js was a rapidly changing framework. The community and Ember Core Team tackled hard problems, many of which felt self-evident. We struck out in a new direction with Ember-CLI, created a bustling addon ecosystem, completed most of the grunt work on HTMLBars, and made huge strides in Ember-Data and API standardization.

As Ember gains adoption, we should take a moment to check our assumptions about who is using the framework and how. A little reflection on what happens in the wild can keep us honest and focused.

With this aim, I’m pleased to announce the unofficial Ember Community Survey!

Completing the survey should take about ten minutes. We will be accepting submissions until February 20th.

Please help us spread the word by sharing:

on your social network feeds, at meetups, and around your office and other communities.

With your answers (all anonymous), we will create some visuals and write up our insights before EmberConf 2015 (March 3-4th). If you have any immediate questions, feel free to email us at survey@201-created.com.

Thanks to @climbingnarc for his continued help organizing this project with 201-created.com.

Say hello to Brian Runnells (@climbingnarc). Brian is an Ember developer working with my consulting company 201 Created on a new project over February and March. He leads a double life as developer and rock climbing blogger. We’re lucky to be working with him, and happy to have him introduce the Ember Community Survey. -Matt

Who is currently developing applications with Ember.js?

What tools are those developers using to build their apps?

What kind of apps are they building?

2015 is an incredible time to be an Ember.js developer. Not only does the framework continue to gain momentum, but there are many features on the horizon. With this, however, comes many questions, like those above. So, when 201 Created began seeking people to help construct a survey for Ember developers, I was excited to take advantage of that opportunity.

Together, we have created a number of questions related to both your personal use of and professional work with Ember. Our goal is to ask the necessary questions about how and why developers are using Ember in order to better inform both the the community at large and the Ember Core Team. These responses will allow us to identify what is going well, where more work needs to be done, and what directions our community is moving in.

As the goal is to have results compiled by March’s EmberConf (tickets are sold out, but hope to see you there!), this survey will be finalized and put out for responses in early February. At this time, we are looking for any feedback you may have regarding the topics and questions we have produced thus far.

Find the survey questions here and share your feedback as a comment. Google provides some documentation about commenting that is good to review if you haven’t used the feature before. You can also contact us directly via survey@201-created.com.


← All Articles