UNPKG

49.9 kBMarkdownView Raw
1version @VERSION@
2=================
3
4Notes
5-----
6
7Deprecations, Removals
8----------------------
9
10Features
11--------
12
13Bug Fixes
14---------
15
16Acknowledgements
17----------------
18
19
20version 0.7.0
21=================
22
23Notes
24-----
25
26* YUI dependency was upgraded to yui@3.10.3
27
28Deprecations, Removals
29----------------------
30* The mojito command line tools included in the mojito repository were deprecated in May. Mojito Developers were asked to install and use the `mojito-cli` npm package. With this release, the **command line tools have been removed** from Mojito. Use of the commands with the latest `mojito-cli` works as before. Also, deprecated commands "profiler" and "gv" cli commands were moved to separate packages.
31
32Note that if an application's continuous integration environment (i.e. Jenkins, Screwdriver) depends on the code for these commands to be included as part of the mojito package, the application package.json [will need to be updated](https://github.com/yahoo/mojito-cli/wiki/NpmInstallation#mojito-cli-commands-and-ci).
33
34CLI change summary:
35
36 * Developers should continue to install `mojito-cli` globally in their development environments to use "mojito" commands from the console. This remains the case for any recent version of Mojito.
37 * Mojito applications depending on `mojito@0.7.0` and doing CI with Screwdriver need to add `mojito-cli` as a devDependency.
38 * `mojito profiler` was re-packaged and can be [installed separately](https://github.com/yahoo/mojito-cli-profiler).
39 * `mojito gv` was re-packaged and can be [installed separately](https://github.com/yahoo/mojito-cli-gv).
40
41More info at the [mojito-cli wiki](http://git.io/jJazAw).
42
43* mojito-carrier-addon and mojito-device-addon are moved to y_mojito package for Yahoo internal developer use only.
44
45Features
46--------
47* PR #1163: Rehydration of data from server to client and from client to server. Any data set thru `mojitProxy.data.set()` or `ac.data.set()` will travel back and forward between the client and server runtime to preserve the state of the mojit instance when using the rpc tunnel.
48
49Bug Fixes
50---------
51* Issue #1159: tunnel request fails if mojito-data-addon is required on the server side controller.
52
53Acknowledgements
54----------------
55
56
57version 0.6.1
58=================
59
60Notes
61-----
62* Mojito contributors can now use the following `npm run-script` shortcuts when working inside the mojito repo:
63 * `npm test`
64 * `npm run unit`
65 * `npm run func`
66* YUI dependency was upgraded to yui@3.10.1
67* Arrow devDependency was upgraded to yahoo-arrow@~0.0.77
68* YCB dependency was upgraded to ycb@~1.0.5
69
70Deprecations, Removals
71----------------------
72
73Features
74--------
75
76Bug Fixes
77---------
78* fix #1151 client-side route-maker error IE6-8
79* fix #1146 use perf.logFile from app.json:perf.logFile if applicable
80* fix callback handling in mojito start sequence
81
82Acknowledgements
83----------------
84Thanks to @chetanankola for discovering and helping with issue #1151.
85
86version 0.6.0
87=================
88
89Notes
90-----
91* `ac.config.getAppConfig()` was reworked to improve performance by computing the app
92config once per request, and reuse across all the mojit instances in the same page using
93the `mojito-config-addon`. This means you have to be extra careful if you attempt to
94change that object, because it might affects other mojits in the same page.
95* `ac.config.getRoutes()` was reworked to improve performance by computing the app
96config once per request, and reuse across all the mojit instances in the same page using
97the `mojito-url-addon`. This means you have to be extra careful if you attempt to
98change that object, because it might affects other mojits in the same page.
99* Using `Y.Model.Vanilla` class on the server side for `ac.data` and `ac.pageData`, while
100using `Y.Model` on the client side. This is a performance optimization, and while the API
101is still the same, but on the server we do not support events on those model instances, while
102in the client, you might want to listen for changes in the model from the binder. In the future
103`Y.Model.Vanilla` will be replace with `Y.Model.Base` when it becomes available in core.
104
105Deprecations, Removals
106----------------------
107* PR [#1103] Droping support for `nodejs` 0.6.
108* `ac.staticAppConfig` was a private api used by mojito to allocate static config for the app,
109and this is now removed. If you need access to the config, you can use `mojito-config-addon`
110to access `ac.config.getAppConfig()`.
111
112Features
113--------
114* PR [#1103] Bringing `windows` to the front row by adding *partial* support for mojito on
115windows. We plan to consolidate this going forward, but until after [travis-ci.org](http://travis-ci.org/)
116supports `windows` [environment](http://about.travis-ci.org/docs/user/ci-environment/) as part of the
117build process to do sanity check, we cannot guarantee that everything will work on `windows`.
118* `mojito-composite-addon` and `mojito-partial-addon` support `ac.flush` from child mojits.
119* Command "npm test" is added to run all mojito unit and functional tests with Phantomjs.
120 Test results can be found under <mojitosrcdir>/artifacts/arrowreport by default.
121 "npm run unit", "npm run func", "npm run doc", "npm run lint" are also added.
122
123
124Bug Fixes
125---------
126
127Acknowledgements
128----------------
129
130version 0.5.9pr1
131=================
132
133Notes
134-----
135* **!IMPORTANT!** This release contains a notable backward-incompatible change. See "Deprecations, Removals" below.
136* The PR [#1059](/yahoo/mojito/issues/1059) adds the Mojito Quickstart Guide application
137to the `examples` directory. The application allows you to view documentation on
138different devices and serves as a reference application. You can view the live application
139at http://y.ahoo.it/mqsg. Also, see the wiki page
140[Mojito Quickstart Guide: Intro](https://github.com/yahoo/mojito/wiki/Mojito-Quickstart-Guide)
141for more information about the application.
142
143Deprecations, Removals
144------------
145* **!Backwards-Incompatible Change!** Using `ac.instance.config` to send data from a controller to a binder has been removed.
146This was never the official approach but was a work-around mentioned in our FAQ until we could support something better.
147We now have an official data channel from controller to binder -- see "Features" below.
148This was removed because sending `instance.config` from the server to the client could possibly leak secure information.
149* The command line tools bundled with mojito have been deprecated. Rather than installing `mojito` globally, please install `mojito-cli` globally instead. Functionality should remain the same. See http://git.io/jJazAw
150* `mojito compile` command was removed. It has been deprecated since 0.5.1.
151* `mojito profiler` has been deprecated. It will be removed in a future release.
152
153Features
154--------
155
156### Data Channel from Server to Client
157
158Introducing `mojito-data-addon` for use in controllers. This AC addon is used to pass
159information from the controller to the binder. After requiring this addon in your
160controller you can use `ac.data.set(name, value)` to expose data to the binder.
161The binder accesses this data with `mojitProxy.data.get(name)`.
162
163The data set via `ac.data.set()` is also available in all templates. Any data given
164to `ac.done()` will be merged over the data given by `ac.data.set()`.
165(This is a shallow merge.)
166
167### Page-Level Data Store
168
169`mojito-data-addon` also introduces the page data, which is accessible thru `ac.pageData`.
170This has a YUI Model API, i.e. `ac.pageData.set(name, value)` and `ac.pageData.get(name)`.
171`pageData` is unique to each request, but is a single store for all mojits of the request,
172and you can use it to share data between mojits in a page. The binder accesses this data
173with `mojitProxy.pageData.get(name)`.
174
175The data set via `ac.pageData.set()` is also available in all templates thru `this.page`
176(for example `{{page}}` in handlebars templates). Keep in mind that if
177`ac.done({page: 'something'})` is specified in your controller, the `page` key will override
178all data set via `ac.pageData`.
179
180This data will be sent to the client side, and rehydrated since the page built at the server
181side will expand its scope to the client. In other words, `pageData` serve as a mechanism
182to share data between mojits and runtimes. `ac.pageData` and `mojitProxy.pageData` provides
183access to the same page model.
184
185Bug Fixes
186---------
187
188Acknowledgements
189----------------
190
191Special thanks to [Steven Lu](/luchenghan) for contributing the Mojito Quickstart Guide app for this release.
192
193version 0.5.8
194=============
195
196Notes
197-----
198
199* The PR [#1062](/yahoo/mojito/issues/1062) fixes the detection problems in YUI that
200where causing multiple issues with Y.JSON.parse and other components. In the current
201implementation, the app itself uses `require('yui')` in a traditional way to avoid any
202potential issues in the future with the detection system in YUI. It also re-enabled
203the ability to run YUI in debug mode in the server side if you happen to use `filter="debug"`
204in `application.json` which has been broken for a long time.
205
206Deprecations
207------------
208
209* "hybridapp" code and resources have been removed. They were purpose built for use with other cocktails components outside mojito, but their development has recently stopped.
210
211Bug Fixes
212---------
213
214* [PR #1062](/yahoo/mojito/issues/1062): fixes the issue with Y.config.global after the upgrade to yui@3.9.1
215* removed a few unnecessary datastructure copies
216
217version 0.5.7
218=============
219
220Notes
221------------
222* A middleware called `mojito-handler-error` has been added to handle
223 middleware errors. If you have redefined the middleware stack and do not have
224 your own error handler, then it is your responsibility to add it so that
225 errors can be handled appropriately.
226
227* An early preview of [`mojito-cli`](https://github.com/yahoo/mojito-cli) has been published. Users can choose to try it with `npm install --global mojito-cli`. There should be no significant changes in functionality. It is intended to replace the functionality provided by installing the mojito npm package globally (which has been deprecated). Notes:
228 * users install mojito-cli package globally (if they choose to in this preview release period).
229 * users should install the mojito package _locally_, as an npm dependency of their application.
230 * all existing mojito command line commands should continue to operate in much the same way.
231 * `mojito create app Foo`, when mojito-cli has been installed, will use `npm` to install `mojito` locally automatically after generating the app files and directories.
232
233Features
234------------
235* Upgraded to YUI 3.9.1
236* [issue #979](/yahoo/mojito/issues/979):
237 * The `mojito-handler-tunnel` middleware was refactored into a middleware
238 substack that more loosens the coupling between the parsing and handling
239 phases of a tunnel request. This means that applications will have an
240 easier time overriding and customizing tunnel behavior.
241 * The URL is now customizable per request using the `tunnelUrl` option for
242 `mojitProxy.invoke()`, but is still subject to the `tunnelPrefix`
243 restriction.
244
245
246Bug Fixes
247------------
248* issue bz6160815: port argument must be an integer
249
250
251version 0.5.6
252=================
253
254Notes
255------------
256* Mojito cli commands will be moving to a separate package `mojito-cli` in
257 upcoming releases, which will be for global installation. The core mojito
258 package will be for bundling with your application.
259
260Deprecations
261------------
262* Mojits shipped with Mojito (like HTMLFrame, tunnel, etc) will play by the same
263rules, no more conditions when we walk them. Before, those mojits were forced
264to not have `res.url` because they should not be used from the client side, that's not
265longer the case.
266
267Bug Fixes
268------------
269* issue #812: only walk the first/shallowest version of each package
270* issue #1016: regression that prevented shaker for controllering CDN urls
271* issue #1026: compatibility with Node.js 0.10 by making all mojits to play by the same rules
272
273
274version 0.5.5
275=================
276
277Deprecations
278------------
279Performance optimizations introduced in this release have resulted in internal API changes.
280This impacts 3rd party components that are using protected or internal store APIs, e.g. [Shaker](/yahoo/mojito-shaker).
281A new Shaker version will be released very soon to address these changes.
282In the meantime, you can follow [mojito-shaker#43](/yahoo/mojito-shaker/pull/43).
283
284Here are details of the API changes.
285
286* We removed store event `getMojitTypeDetails`. The replacement is [`resolveMojitDetails`](http://developer.yahoo.com/cocktails/mojito/api/classes/ResourceStore.server.html#event_resolveMojitDetails), though the datastructure is different.
287* We removed store event `mojitResourcesResolved`.
288* We removed `store.getResources()`.
289* We added `store.optimizeForEnvironment()`.
290* We added `store.makeStaticHandlerDetails()`.
291* `store.yui.getAllURLResources()` is now called [`store.yui.getAllURLDetails()`](http://developer.yahoo.com/cocktails/mojito/api/classes/ResourceStore.server.html#method_getAllURLDetails) and returns a different datastructure.
292* For both [`store.getResourceContent()`](http://developer.yahoo.com/cocktails/mojito/api/classes/ResourceStore.server.html#method_getResourceContent) and [`store.procesResourceContent()`](http://developer.yahoo.com/cocktails/mojito/api/classes/ResourceStore.server.html#method_processResourceContent), the datastructure representing the resource has changed.
293* [`store.getResourceVerions()`](http://developer.yahoo.com/cocktails/mojito/api/classes/ResourceStore.server.html#method_getResourceVersions) should not be called during runtime. It can still be called during the events that happen during preload.
294* [`store.yui.getConfigShared()`](http://developer.yahoo.com/cocktails/mojito/api/classes/RSAddonYUI.html#method_getConfigShared) now just takes the `env` argument.
295* We removed `store.yui.getConfigAllMojits()`. Some users were calling `getConfigAllMojits` and using the results with `getConfigShared` to configure a YUI instance. Now instead we suggest using `getModulesConfig()` to replace this pair of calls.
296* We added [`store.yui.getModulesConfig()`](http://developer.yahoo.com/cocktails/mojito/api/classes/RSAddonYUI.html#method_getModulesConfig).
297* We added [`store.yui.getYUIConfig()`](http://developer.yahoo.com/cocktails/mojito/api/classes/RSAddonYUI.html#method_getYUIConfig).
298* [`store.yui.getAppSeedFiles()`](http://developer.yahoo.com/cocktails/mojito/api/classes/RSAddonYUI.html#method_getAppSeedFiles) now takes a yui configuration as the second argument.
299* `store.yui.getYUIURLResources()` is now called `store.yui.getYUIURLDetails()` and returns a different datastructure.
300
301Please see the API docs for details of each.
302
303Features
304------------
305* Global models thru `ac.models.expose()` upgraded from experimental to beta.
306* Support for Handlebars helpers through `mojito-helpers-addon` and support for global Handlebars helpers using `ac.helpers.expose()`. This is an experimental feature!
307* Introducing error propagation in `mojito-composite-addon` by using the flag `propagateFailure` in a child.
308* Introduced a clear separation between YUI core modules and app-specific YUI modules. YUI core modules are now served from CDN by default; they are only served by the app origin server if `staticHandling.serveYUIFromAppOrigin` is set in `application.json`. This change optimizes the initial load time of the app as well as its offline capabilities when using [mojito build html5app](http://developer.yahoo.com/cocktails/mojito/docs/reference/mojito_cmdline.html#build-system).
309* Improved Resource Store: minimized memory footprint.
310* Upgraded to YUI 3.8.1
311
312Bug Fixes
313------------
314* [#25](/yahoo/mojito/issues/25) mojito-composite-addon error propagation
315* [#293](/yahoo/mojito/issues/293) HTMLFrameMojit should honor child metas
316* Fixes the `Cache-Control` header for static assets.
317* Fixed hybrid build issue
318* Fixed lingering occurrences of `store.yui.getConfigAllMojits()`
319* Fix for `forceRelativePaths` for YUI loader when using `mojito build`, making root and base to be relative when needed.
320* (sweetandsour2) Fix for client side hooks, bug fix in template hooks.
321
322
323version 0.5.4
324=================
325
326Deprecations
327------------
328* We dropped the Mu library in favor of Handlebars -- Handlebars is used everywhere, including for parsing Mu templates.
329Even though Mustache is a subset of Handlebars, this might introduce some encoding issues, especially because Handlebars does automatic encoding of `{{}}` sections to provide some basic security against script injections.
330If you are encoding data in your controller for your Mustache views, you no longer need to do so, and by using `{{}}` you will be covered.
331On the other hand, if you don't want Handlebars to apply the default encoding, just use `{{{}}}` to print the original value.
332
333Features
334------------
335* Support for Handlebars partials
336* Dropped Mu library: any `*.mu.html` view/template will be processed using HB engine
337* Global models thru `ad.models.registerGlobal`
338* Templates warm-up thru `preloadTemplates` configuration for small apps.
339* Support for external URLs in `yui.config.seed` for custom YUI versions on the client side.
340
341Bug Fixes
342------------
343* Solving conflits generated by the hook system.
344* lock yahoo-arrow version to 0.0.73
345* Revert "Reduced memory consumption at server start by removing an apparently unnecessary meta-data copy operation..."
346* adding support for a more flexible seed structure to support external urls. this helps to control the yui version on the client.
347* removing mustache engine in favor of handlebars based on [#367](/yahoo/mojito/issues/367) by @mridgway
348* supporting registration of global models
349* consolidating application.json->viewEngine->cacheTemplates as a static config across the board.
350* adding support for partials in the store. Views within partials/* folder are now considered partials.
351
352
353version 0.5.3-1
354=================
355
356Bug Fixes
357------------
358* Revert 3a5822a "Reduced memory consumption at server start by removing an apparently unnecessary meta-data copy operation"
359
360
361version 0.5.3
362=================
363
364Features
365------------
366* new mojito and mojito-app instrumentation hooks
367* performance improvements
368* simplification of the frame mojit to facilitate inheritance and brand new frames per app.
369
370Bug Fixes
371------------
372* [#919](/yahoo/mojito/issues/919) Added examples of YAML configuration and linked…
373* [#928](/yahoo/mojito/issues/928) Remove Y! copyright from generated code
374* [#954](/yahoo/mojito/issues/954) fix for app failures when deploying to nodejitsu.
375
376
377version 0.5.2
378=================
379
380Features
381------------
382
383### Performance Improvements
384
385From `0.5.1` to `0.5.2` we have implemented a series of micro-optimizations.
386As a result, Mojito is twice as fast, uses half the memory footprint, and takes half the time to boot the application based on our internal metrics.
387More information can be found on our [Trello board](http://tinyurl.com/axvd3tt).
388This improves the response time to ~40ms response time for an application with 52 mojits, which represents less than 1ms per mojit.
389
390### Comments in JSON files and YAML Support
391
392Configuration files, including `application.json`, `defaults.json`, `definition.json`, etc., can become pretty big for complex applications, and not having comments can drastically impact productivity and on-boarding for new developers.
393As of this version, we support comments in those files.
394The comments are YAML comments, they start with `#`.
395
396As well, we just brought back support for `.yml` and `.yaml` that was previously introduced in Mojito `0.4.x`.
397
398### Logs Formatter
399
400In `0.5.0`, we removed the mojito `logger` and started using `YUI Log` in its pure form.
401As a result of the formatting process implemented by the `yui-log-nodejs` module, the logs were formatted even when the application was running in a runtime without `tty`.
402This was partially fixed in this new version (for runtime execution where performance is critical), and we plan to finish the migration for the Resource Store's logs in `0.5.3`.
403
404
405Bug Fixes
406------------
407* [bz5667423] Add support for including files in a configuration bundle
408* Added support for JavaScript-style comments in JSON files
409* [bz5964521] test output is always colorized -- includes escape codes when saved to file
410* micro-optimization: replacing runInNewContext with runInContext
411* fix two newsboxes unit tests, misc
412* update copyright to 2013
413* [doc] Added FAQ about setting expiration of a cookie.
414* update package.json in archetypes for mojito 0.5.x & node >0.6
415* do not colorize test.js output if there is no tty [gh809,bz5964521]
416* Functional test changes to support SD
417* jslint tests along with template for general cli testing
418* [bz6023234] prefix for hybridapp/crt "//yahoo.com"
419* Update docs/dev_guide/getting_started/mojito_getting_started_tutorial.rst
420* removed shelljs
421* honor --descriptor for --cli and --unit as well
422* Travis cleanup
423* [doc] Updated documentation for running Mojito's built-in unit/functional tests.
424* more unit tests for ActionContext
425* Update docs/dev_guide/intro/mojito_apps.rst
426* Add more unit tests for params.common and view engine handlebar
427* a little more careful about transforming ac.done() into a no-op
428* Update docs/dev_guide/intro/mojito_mvc.rst
429* [doc] Documentation for how to configure YUI for Mojito applications.
430* Update docs/dev_guide/intro/mojito_mvc.rst
431* unit tests for `build/*.js`
432* supporting yui.config.groups.app.comboSep=& without mangling
433* dispatcher coverage
434* .travis.yml debug, misc
435* Update docs/dev_guide/topics/mojito_testing.rst
436* Update docs/dev_guide/intro/mojito_binders.rst
437* Add more unit tests for util.
438* fixed client-side unit tests
439* Modify files to workaround a jslint error
440* [gh238] [bz5667423] support for multiple application configuration files
441* fix missing snapshot.packages in build hybridapp
442* [doc] Added links to archived docs.
443* unformatted logs when running in production systems
444* Update docs/dev_guide/code_exs/calling_yql.rst
445* add unit test for version
446* [doc] Docs add links to presentation given by Caridy at YUIConf 2012.
447* Update docs/dev_guide/reference/mojito_troubleshooting.rst
448* re-enable yaml support
449* [doc] Added FAQ discussing how to re-use and extend mojits.
450* workaround how arrow is tweaking with console.debug()
451
452
453version 0.5.1
454=================
455
456Notes
457------------
458* `mojito compile rollups` command is no longer needed and has been removed -- comboing is now done at request time.
459* `mojito compile` commands are deprecated in favor of [Shaker](/yahoo/mojito-shaker)
460* for hybridapp builds, the application.json config `builds.hybridapp.forceRelativePaths: true` is broken for the time being. This makes testing with a browser in a non-chrooted more difficult.
461* NOTICE: 0.5.x has various configuration and API changes from 0.4.x, please also review [0.5.0 release notes](ReleaseNotes0_5_0) if you are upgrading your application from pre-0.5.x versions.
462
463Features
464------------
465* comboing of mojito and application javascript files are at request time
466* improved performance/latency
467* improved internal test and testability
468* improved 0.5.x documentation
469
470Bug Fixes
471------------
472* fix issue #835 more careful about caching results of expandInstanceForEnv()
473* adjusting ac.url.make routine to avoid accepting strings for querystring. avoiding any parsing or stringifing routine at…
474* fix mojito create -p option - add {{port}} to application.json
475* fix resolve loader config for hybridapp/IDE/CRT in 0.5.x
476* fix input handling and error message for jslint mojit command
477* better support of older browsers
478* HTMLFrameMojit title now says 'Powered by Mojito', not 'Powered by Mojito 0.2'
479
480
481version 0.5.0
482=================
483
484Notes
485------------
486* **IMPORTANT** This release contains notable backward-incompatible changes, all for the sake of significantly increased performance.
487
488Backward Compatibility Changes
489--------------------------------
490
491### Mojito No Longer Adds Common ActionContext Addons
492
493In the past, a subset of the addons provided by Mojito framework were attached on every `ActionContext` object (which are created per request, per mojit instance in the page).
494The specific list was mojito-config-addon, mojito-url-addon, mojito-assets-addon, mojito-cookie-addon, mojito-params-addon, mojito-composite-addon.
495This resulted in overhead for every mojit in the page.
496As part of 0.5.0, all requirements have to be specified in the controller definition. e.g:
497
498 YUI.add('Foo', function(Y, NAME) {
499
500 Y.namespace('mojito.controllers')[NAME] = {
501
502 index: function(ac) {
503 // ac.params.* is now available
504 }
505
506 };
507
508 }, '0.0.1', {requires: ['mojito', 'mojito-params-addon']});
509
510As of 0.5.0, no addon is attached unless it is required. The only public members of `ActionContent` object are `ac.done`, `ac.error`, and `ac.flush`.
511
512Recommendations to upgrade:
513
514* check every controller in your app, and check if it is using `ac.*`, and add the corresponding requirements.
515* the most common addons are: config, params, url, assets.
516
517
518### Access to Models via a Property
519
520Models are no longer computed and attached to `ActionContext` by default.
521In other words, `ac.models.foo` is no longer a valid way to access a model.
522Computing and attaching models automatically, even when they were not really needed, added overhead during the page rendering process.
523Instead, we want Mojito to be more strict in defining and exposing structures automatically.
524
525In 0.5.0, if you need to use a model in a controller (defined at the mojit level, or at the application level), you need to:
526
527* require a new addon called `mojito-models-addon` in your controller.
528* require the module in your controller.
529* use `ac.models.get('foo')` to get a reference of the model.
530
531Here is an example:
532
533 YUI.add('DemoModelFoo', function(Y, NAME) {
534 Y.namespace('mojito.models')[NAME] = {
535 init: function(config) {
536 this.config = config;
537 },
538 getData: function(callback) {}
539 };
540 }, '0.0.1', {requires: []});
541
542 YUI.add('Foo', function(Y, NAME) {
543 Y.namespace('mojito.controllers')[NAME] = {
544 index: function(ac) {
545 ac.models.get('DemoModelFoo').getData(function (data) {
546 // data from model available here
547 });
548 }
549 };
550
551 }, '0.0.1', {requires: ['mojito', 'mojito-models-addon', 'DemoModelFoo']});
552
553> Note: the model name doesn't have to match the yui module name for the model anymore.
554
555
556### `init` Method in Controllers is Gone
557
558The `init` method on the controller is now deprecated and should be removed.
559In many cases, the `init` method was just storing a reference of the `config` parameter to use it later on.
560This is no longer available, and the `init` method will not be executed.
561
562If you need to access the mojit `config` in an actions, you should:
563
564* require `mojito-config-addon` in the controller.
565* use `ac.config.get()` to get the `config`
566
567> Note: do not try to store a reference of that config, as it is not safe, More details below.
568
569
570### `ac.app.*` is Gone
571
572For performance reasons, to avoid computing app config per mojit instance, per request, when the majority of the time it is not needed, we completed the transition to `mojito-config-addon` add-on.
573This change affects `ac.app.*`, specifically `ac.app.config` which was commonly used to access the computed `application.json` configuration per `context`.
574If you need to access the application `config` in an action or another add-on, you should:
575
576* require `mojito-config-addon` in the controller.
577* use `ac.config.getAppConfig()` to get the former `ac.app.config`
578
579
580### Controllers Can No Longer Run Forever
581
582Mojito now imposes a timeout on the dispatch of the action in the controllers.
583Starting with 0.5.0 there is a "reaper" which imposes a timeout.
584Actions must call `ac.done()` or `ac.error()` before the timer expires or the system will log a warning and invoke `ac.error()` with a timeout error.
585
586This can be configured by the `actionTimeout` setting in `application.json`.
587It contains the maximum number of milliseconds that a controller action is allowed to run before the action is timed out.
588The default value is `60000` (60 seconds).
589
590
591### Mojit and AC Addon Naming Conventions Changes
592
593Mojito is more restrictive in how you names mojits and add-ons. There are 4 new rules:
594
595* `addon` namespace should match the filename. E.g. `ac.foo` corresponds to `addons/ac/foo.common.js`.
596* The name of the mojit, which is the name of the folder, should match the language bundle, including the filename of the bundle and its definition. E.g. `Foo` mojit can have `lang/Foo_da-DK.js`, and the content should be `YUI.add('lang/Foo_da-DK', function (Y) { Y.Intl.add('Foo', 'da-DK', {}); });`
597* Controller YUI module name should be same as directory.
598* YUI modules need to have unique names, regardless of selector.
599
600
601### `log` Config in `application.json` is Gone
602
603In previous versions, the console log was separated for client and server, and between Mojito and YUI.
604We decided to leverage the YUI Logger, and unify this setting under a single configuration, actually the YUI configuration in `application.json`:
605
606 "log": {
607 "client": {
608 "level": "error",
609 "yui": false
610 },
611 "server": {
612 "level": "error",
613 "yui": false
614 }
615 }
616
617is now:
618
619 "yui": {
620 "config": {
621 "debug": true,
622 "logLevel": "error"
623 }
624 }
625
626and we recommend this setting for production:
627
628 "yui": {
629 "config": {
630 "debug": false,
631 "logLevel": "none"
632 }
633 }
634
635To customize this for client or server, you can use the runtime context.
636Also, you can now use `logExclude` and `logInclude`.
637More information at http://yuilibrary.com/yui/docs/api/classes/config.html.
638
639
640### Other Settings Changes in `application.json`
641
642The following are gone:
643
644* `embedJsFilesInHtmlFrame`
645* `shareYUIInstance`
646* in the `yui` section:
647 * `base`
648 * `dependencyCalculations`
649 * `extraModules`
650 * `loader`
651 * `url`
652 * `urlContains`
653
654
655### `mojito test` No Longer Tests the Framework
656
657In the past, `mojito test` without any other parameter was running all unit tests for mojito framework, and this is no longer the case.
658We moved all the tests to `arrow`, more details here: https://github.com/yahoo/mojito/tree/develop/tests
659
660You can continue using `mojito test app path/to/app` and `mojito test mojit path/to/mojit`, and the behavior is still the same.
661
662> Note: this change is only relevant for contributors.
663
664
665### `.guid` is Gone
666The `.guid` member of Mojito metadata (such as binder metadata) is now gone.
667Often there's an associated member which more specifically expresses the intent of the unique ID (for example `.viewId` or `.instanceId`).
668
669Features
670------------
671* Speed: TODO more details.
672* Logging now uses `Y.log()` directly, instead of our own wrapper. This simplifies usage and enables subscribing to the YUI log events.
673* Upgraded `yui` dependency to `3.7.3` (or greater).
674* Combo handling is now built in to Mojito server.
675* New hybrid app archetype to help create apps for use in technologies such as phonegap.
676
677Bug Fixes
678------------
679* [#70](/yahoo/mojito/issues/70) Simplify logging
680* [#525](/yahoo/mojito/issues/525) example unit tests crash or fail
681* [#651](/yahoo/mojito/issues/651) Expanded instances are bleeding
682* [#736](/yahoo/mojito/issues/736) Content Error in documentation
683* bz5472979 server resources in build
684* bz5886351 cli bin/mojito uses wrong copy
685* bz5892364 (archetype) mojito-client not loaded for hybrid app
686* bz5904449 garbled console output on node 0.8+
687* bz5914052 do real buffer calculus for better UTF8 and binary support
688
689
690version 0.4.9
691=================
692
693Notes
694------------
695* Command line warning and error output used to go to stdout, they now go to stderr.
696* Version 0.4.9-2 fixes the output of the test coverage report for `mojito test -c app .`, which was incorrect for 0.4.9.
697
698Features
699------------
700* New `mojito build hybridapp`, requires snapshot name and tag options.
701
702Bug Fixes
703------------
704* Add yuitest-coverage dependency.
705* Add yaml suport, including work from pr580 and pr670.
706* Fix bz4404935, including work from pr580 and pr670
707* Non-functional changes to cli fixes issue #715 typo in info error msg.
708* Fix bz5895425 resources for hybridapp/crt were 500/not found as web app.
709* Fix bz5904449 garbled console output on node 0.8+ if process.stdout is not a tty (i.e. a pipe) the console.log interpreted…
710* Fix bz5898249 merge source application.json's build.hybridapp.packages object into the build's ./appname/package.json dependencies…
711* Fix bz5472979 server resources in build server affinity resources do not need to be uri addressable. with this change store.getAllUrls()…
712* Fix bz5886351 cli bin/mojito uses wrong copy.
713* Fix bz5892364 (archetype) mojito-client not loaded for hybdridapp.
714* Fix bz5886351 cli: bin/mojito launches wrong copy the cli entry point bin/mojito should always load and run the code.
715
716
717version 0.4.8
718=================
719
720Notes
721------------
722* All performance regressions will be addressed in an upcoming release.
723
724Features
725------------
726* [#643](/yahoo/mojito/issues/643) new `hybrid` archetype
727 * new archetype: mojito create app hybrid myapp
728 * new build type: mojito build hybrid path/to/packages/dir
729 * new custom archetypes: mojito create custom path/to/your/archetype mything
730
731Bug Fixes
732------------
733* [#645](/yahoo/mojito/issues/645), bz5472979 fix server resources in build
734* [#650](/yahoo/mojito/issues/650) [docs] Added a prereq for doing the code example, added a link
735* [#546](/yahoo/mojito/issues/546) multiple jslint errors in developer-guide and getting-started code examples
736* [#547](/yahoo/mojito/issues/547) errors in basic_yql example (getting-started-guide/part2)
737* [#570](/yahoo/mojito/issues/570) documentation - add api_key to the binders/index.js in the code example on Binding Events
738* fix path for create mojit.
739
740
741version 0.4.7
742=================
743
744Notes
745------------
746* **IMPORTANT - server.js compatibility changes**
747This release requires changes to any application's index.js file and server.js file to properly launch.
748The templates in `mojito/lib/app/archetypes/app/default` for index.js and server.js are the appropriate content to use in any existing applications.
749For new applications these files are automatically used when the `mojito create app` command is invoked to create a new application.
750
751Features
752------------
753* [#565](/yahoo/mojito/issues/565) Added support for `/crossdomain.xml` and `/robots.txt`
754
755Bug Fixes
756------------
757* [#525](/yahoo/mojito/issues/525) `mojito test app|mojit` failed for archetype-code…
758* [#615](/yahoo/mojito/issues/615) [doc] Added func/unit test instructions.
759* [#546](/yahoo/mojito/issues/546) multiple jslint errors in developer-guide
760* [#621](/yahoo/mojito/issues/621) [docs] Fixed a syntax issue for using run.js.
761* [#624](/yahoo/mojito/issues/624) Add getter to avoid exposing `_app` for Manhattan use.
762* [#625](/yahoo/mojito/issues/625) Move app init so any `getHttpServer` call returns initialized app instance...
763* [#598](/yahoo/mojito/issues/598) The routing configuration documentation covers the 'regex' property.
764* [#628](/yahoo/mojito/issues/628) Fix start logic.
765* [#602](/yahoo/mojito/issues/602) Rewrote item in the FAQ regarding passing data from the controller to the binder.
766
767
768version 0.4.6
769=================
770
771Notes
772------------
773* All performance regressions will be addressed in an upcoming release.
774
775Deprecations
776------------
777As of this release, Mojito has changed the way the application boots up. Update the file `server.js` that is at the root dir of your application. Here is an example:
778
779 ```javascript
780 var Mojito = require('mojito');
781 var app = Mojito.createServer({
782 context: {}
783 });
784 // Mojito 0.4 and 0.5 compatibility...
785 module.exports = app.start ? app.start() : app;
786 ```
787
788Features
789------------
790* [#265](/yahoo/mojito/issues/265) Mojito can now be started using the standard node command.
791
792Bug Fixes
793------------
794None.
795
796
797version 0.4.5
798=================
799
800Notes
801------------
802* Some performance regressions remain from 0.4.0 and will be addressed in an upcoming release.
803
804Features
805------------
806* Improved JavaScript parse error messages.
807* Improved functional test stability.
808
809Bug Fixes
810------------
811* [#13](/yahoo/mojito/issues/13) ContextController cache never cleans up
812* [#461](/yahoo/mojito/issues/461) build html5app command - the "builds.html5app" key in "application.json" is not context aware
813* [#482](/yahoo/mojito/issues/482) improve error handling and messaging
814* [#496](/yahoo/mojito/issues/496) Compatibility with Node.js 0.8
815* [#507](/yahoo/mojito/issues/507) Add "hi" group in dimensions.json
816* [#508](/yahoo/mojito/issues/508) better error message for javascript parse errors
817* [#519](/yahoo/mojito/issues/519) Adds a --path option to run.js to allow specifying a path to find the test descriptors or applications
818* [#522](/yahoo/mojito/issues/522) fixed multiple typos in the code example as well as typo in explanation
819* [#547](/yahoo/mojito/issues/547) Updated YQL key used for examples
820
821
822version 0.4.4
823=================
824
825Notes
826------------
827* Some performance regressions remain from 0.4.0 and will be addressed in an upcoming release.
828
829Features
830------------
831* [Arrow](/yahoo/arrow) unit and functional tests are run by [Travis](http://travis-ci.org/yahoo/mojito).
832
833Bug Fixes
834------------
835* [#438](/yahoo/mojito/issues/438) [Shaker](/yahoo/shaker) 2.0 compatibility
836* [#78](/yahoo/mojito/issues/78) Client resource store implementation
837* [#77](/yahoo/mojito/issues/77), [#76](/yahoo/mojito/issues/76) YUIDocs for resource store
838* [#429](/yahoo/mojito/issues/429) PUT requests not handled correctly
839* Fixed a browser incompatibility with XML output
840* fixed how commands instantiate the store
841* performance: use Y.mojito.util.copy() instead of Y.clone()
842* performance: removed Y.clone() from YCB library
843* fix multiple done() calls in client-side Handlebar renderer, consequence of fixing [#408](/yahoo/mojito/issues/408)
844
845
846version 0.4.3
847=================
848
849Bug Fixes
850------------
851* Fix buffer mojito040
852* add node 0.8 compatibility
853* Travis CI Configuration
854* fix broken UTs in mojit skeletons
855* Fixed examples so that they should work with shareYUIInstance
856* Remove YCB and depend on ycb npm package
857* honoring context.lang in the loader
858* Fix for handlebar renderer when ac.flush() is called more than once
859* Moved fixtures; Migrated resource store addon tests
860* change example & fixture mojito dependency to >0.3
861* Store client url fix
862* Remove i13n from public mojito
863* fix store unit test
864* fix (and un-ignore) the resource store unit test for optional YUI modules
865* Remove i13n from public mojito
866* make nice names for the pids
867
868
869version 0.4.2
870=================
871
872Notes
873------------
874* This release is the bleeding edge of our development tree. To install the most stable, production-ready Mojito release, use `npm install mojito@stable`.
875
876Features
877------------
878### Handlebars
879
880Handlebars is now supported and is the default view engine for new projects. We are also recommending that projects change their view engine from Mustache to Handlebars for performance and stability reasons.
881Big thanks to [Caridy Patino](/caridy) for this contribution.
882
883* Made handlebars the default renderer for new projects and all examples [#365](/yahoo/mojito/issues/365)
884* Added deprecation warning for Mu [#369](/yahoo/mojito/issues/369)
885* [#270](/yahoo/mojito/issues/270): Added unit tests for client and server handlebars engines
886* Added client side handlebars engine; Cleaned up jslint errors with server side engine
887* cleaning up the handlebar wrapper for mojito as a view engine for the server side.
888* adding support for handlebars for the server runtime only for now.
889
890### Reason Phrase
891
892Providing the ability to provide a `reasonPhrase` property when calling `ac.error`.
893
894* [#273](/yahoo/mojito/issues/273), [#300](/yahoo/mojito/issues/300) allow custom `reasonPhrase` in ac.error -- Thanks [Fabian Frank](/FabianFrank)!
895
896### shareYUIInstance
897
898It was discovered that `shareYUIInstance` was not usable in previous versions.
899We have addressed some of the issues such that `shareYUIInstance` should be usable, although should be considered experimental.
900This configuration now works in the following way:
901
902Default value is `false` at app level, mojits can override the app config by specifying `shareYUIInstance` in their defaults.json (parallel to the config key).
903
904* [#357](/yahoo/mojito/issues/357), [#386](/yahoo/mojito/issues/386): Fixed `shareYUIInstance`
905
906### Docs
907
908* Reorganized the document, added links to images, section IDs, rewrote sections, and edited.
909* Adding architecture images.
910* Added a link to the RS from the selector property and an example that you cannot add the selector * property to the defaults.json file of a mojit.
911* Added the 'selector' property to the config docs and made a note in the RS docs that the selector can only be set in application.json.
912* Added the --context option to the build and start commands.
913* Added the tunnelTimeout property to the application config object.
914
915Bug Fixes
916------------
917* fix [#375](/yahoo/mojito/issues/375), unified handling of frameworkName, appName, and prefix [#383](/yahoo/mojito/pull/383)
918* Set server runtime when handling tunnel calls. [#242](/yahoo/mojito/issues/242) - Thanks Fabian Frank!
919* jslint command now uses node-jslint npm module; Fixed jslint errors from jslint upgrade [#360](/yahoo/mojito/issues/360)
920* [#352](/yahoo/mojito/issues/352) archetypes now specify a version of mojito similar to that which uses them [#355](/yahoo/mojito/issues/355)
921* when using the loader at the server side to generate combo urls we should pipe the yui config into the loader settings otherwise some settings will not be honored. [#350](/yahoo/mojito/issues/350)
922* guard against missing edges in `mojito gv` [#349](/yahoo/mojito/issues/349)
923* Removed DaliProxy and adding application configurable tunnel timeout [#345](/yahoo/mojito/issues/345)
924* [Fix bz5712477] Make sure to callback when there is an error [#338](/yahoo/mojito/issues/338)
925* Porting mojito doc over to the new yuidocjs [#243](/yahoo/mojito/issues/243) - Thanks Fabian Frank!
926* [#270](/yahoo/mojito/issues/270): Added unit tests for client and server handlebars engines
927* [#357](/yahoo/mojito/issues/357), [#386](/yahoo/mojito/issues/386): Fixed `shareYUIInstance`
928
929
930version 0.4.0
931=================
932
933Notes
934------------
935* This release contains a significant rewrite of an important subsystem of Mojito, the resource store.
936Also, with this release, the resource store becomes part of the public API of Mojito.
937It's an advanced feature, however, and is only needed if you intent to change how Mojito interprets and uses files on the filesystem.
938
939Deprecations
940------------
941* You will now need to configure the iphone selector by hand (`{"settings": ["device:iphone"], "selector":"iphone"}`) in your `application.json` files. (This resource store no longer assumes the selector is just the device.)
942* In a mojit's `package.json`, the version check is now spelled `engines.mojito` instead of `yahoo.mojito.version`.
943* In a mojit's `package.json`, `config.mojito` is now spelled `yahoo.mojito`.
944* The second argument to `serializeClientStore()` is gone. (This was pretty much internal to mojito anyway, so likely no one will miss it.)
945* The second argument to `getAppConfig()` is gone. That method now *just* returns the application configuration (from `application.json`). (This was pretty much internal to mojito anyway.)
946
947Bug Fixes
948------------
949* issue [10](/yahoo/mojito/issues/10): Ensure Mojito can handle YUI module names with underscores
950* issue [32](/yahoo/mojito/issues/32): "mojito compile rollups" using dot notation in the name of the css files will make compile to discard some of them
951* issue [50](/yahoo/mojito/issues/50): mojito start loads tests from addons
952* issue [54](/yahoo/mojito/issues/54): "mojito compile inlinecss" has unexpected behavior when there is a css file name that contains the string "iphone"
953* issue [59](/yahoo/mojito/issues/59), bz 5380714: test files under addons/ac/ are loaded when mojito starts
954* issue [95](/yahoo/mojito/issues/95), bz 4647440: Proper Mojito version number comparison
955* issue [109](/yahoo/mojito/issues/109): Refactor certain complicated parts of the store
956* issue [110](/yahoo/mojito/issues/110): Detect duplicate resource ids on cookdown
957* bz 4647169: considering making a utility YUI object in ResourceStore
958* bz 5362206: Need ability to select controller, view, model and binder based on context
959* bz 5495519: mojito is not loading - stuck retrieving all the datetype-date-format for each locale
960* bz 5530096: Mojito tries to parse .json~ files in [mojit]/specs/
961* bz 5541500: mojito not doing fallback
962* bz 5609501: L10n: Root strings file is not used by default when a non-root strings file is present
963
964
965version 0.3.30
966=================
967
968Notes
969------------
970* Mojito depends on the latest patch release of YUI, currently YUI 3.5.1-2.
971This version of YUI fixes a [Y.io issue](/yui/yui3/commit/4b03344978520a7e55dd70f461b21cf81f33aeac) which appeared in the last release.
972Also, as with the last Mojito release, YUI 3.5.x has removed built-in jsdom support.
973Server code that depends on a DOM will cause Mojito to throw an exception on startup.
974A warning will now be issued for known DOM dependent modules matching this criteria.
975Folks are asked to either move DOM dependencies to client affinities or binders, or create the required host objects for your application's DOM requirements.
976See [http://yuilibrary.com/yui/docs/yui/nodejs.html](http://yuilibrary.com/yui/docs/yui/nodejs.html).
977There may also be other app-specific issues with the upgrade in YUI.
978
979Deprecations
980------------
981
982Features
983------------
984* Add --print option to jslint usage message
985* Performance Optimization: Defer RouteMaker Instantiation in URL Addon
986* yuitest cleanups
987* rm local copy of mime, use npm mime module instead
988* Remove local glob.js and replace with glob npm package
989* Added client-side unescape of escaped content
990* Adding namespacing to Mojito components
991* lots of documentation updates
992
993Bug Fixes
994------------
995* Alter escaping to URI escaping to repair regressions
996* Make sure the callback signature is what the supplied Function expects
997* Use command-line context in "mojito build html5app" command
998
999
1000version 0.3.29
1001=================
1002
1003Notes
1004------------
1005* Mojito depends on the latest patch release of YUI, currently YUI 3.5.1-2.
1006This version of YUI fixes a [Y.io issue](/yui/yui3/commit/4b03344978520a7e55dd70f461b21cf81f33aeac) which appeared in the last release.
1007Also, as with the last Mojito release, YUI 3.5.x has removed built-in jsdom support.
1008Server code that depends on a DOM will cause Mojito to throw an exception on startup.
1009A warning will now be issued for known DOM dependent modules matching this criteria.
1010Folks are asked to either move DOM dependencies to client affinities or binders, or create the required host objects for your application's DOM requirements.
1011See [http://yuilibrary.com/yui/docs/yui/nodejs.html](http://yuilibrary.com/yui/docs/yui/nodejs.html).
1012There may also be other app-specific issues with the upgrade in YUI.
1013* Because of the YUI situation, both the latest and stable tags on npm point to Mojito 0.3.26.
1014To install this release you need to specify version 0.3.29 explicitly (either `npm i mojito@0.3.29` or via package.json).
1015
1016Bug Fixes
1017------------
1018* fixed the HelloMojit-tests in the default mojit archetype to prevent a test failure when running `mojito test app .` (as indicated in the Getting Started tutorial). The objects are not equal even if they have the same elements
1019* updated controller.server.js and controller.server-tests.js code examples in getting_started to reflect the files generated by mojito 0.3.26
1020* [bz5472517] Error on server doesn't propagate to client
1021
1022
1023version 0.3.28
1024=================
1025
1026Notes
1027------------
1028* Mojito depends on the latest patch release of YUI, currently YUI 3.5.1-2.
1029This version of YUI fixes a [Y.io issue](/yui/yui3/commit/4b03344978520a7e55dd70f461b21cf81f33aeac) which appeared in the last release.
1030Also, as with the last Mojito release, YUI 3.5.x has removed built-in jsdom support.
1031Server code that depends on a DOM will cause Mojito to throw an exception on startup.
1032A warning will now be issued for known DOM dependent modules matching this criteria.
1033Folks are asked to either move DOM dependencies to client affinities or binders, or create the required host objects for your application's DOM requirements.
1034See [http://yuilibrary.com/yui/docs/yui/nodejs.html](http://yuilibrary.com/yui/docs/yui/nodejs.html).
1035There may also be other app-specific issues with the upgrade in YUI.
1036
1037Features
1038------------
1039* [726a2e4](/yahoo/mojito/commit/726a2e4) Added -p option for jslint results to sdtout
1040
1041Bug Fixes
1042------------
1043* [#231](/yahoo/mojito/issues/231) Update sys references to util references.
1044* [#219](/yahoo/mojito/issues/219) [bz5651900] stop mojit data memory leak - record dynamically
1045* [#223](/yahoo/mojito/issues/223) [bz5646042] log warning if server mojit has DOM dependency.
1046* [#232](/yahoo/mojito/issues/232) [bz5649382] Fix for `mojito test app`.
1047* fix dynamic mojit regression introduced in [2dd7313](/yahoo/mojito/commit/2dd7313)
1048* fix unit test errors in build 130
1049* [bz5491914] Fix client exception on `ac.error()`
1050* [bz5649346] Updates yui and yuitest dependencies; +FreeBSD
1051* [bz5494997] Fix for Mojito client throwing on tunnel timeout
1052* More null fixes for Mustache
1053* [bz5590319] Unicode and/or HTML escaping for config data.
1054
1055
1056
\No newline at end of file