Skip to content
This repository has been archived by the owner on Oct 30, 2018. It is now read-only.

seed refactor #997

Merged
merged 11 commits into from
Feb 23, 2013
Merged

seed refactor #997

merged 11 commits into from
Feb 23, 2013

Conversation

caridy
Copy link
Contributor

@caridy caridy commented Feb 21, 2013

Goals:

  • Reduce the memory allocation when YUI core modules should not be served from local server (default configuration)
  • Clear separation between YUI core modules and app-level modules (including synthetic modules)
  • As part of the separation, the seed will have, at least, 2 files, YUI Core Seed + App Seed.
  • Support for relative path when using mojito build command.

Changes:

  • moving logic to generate seed files into yui rs addon from deploy ac addon.
  • making root and base for yui and app group to correlate.
  • introducing staticHandling->serveYUIFromLocal configuration to disable serving yui from local app by default to preserve memory.

Basically, this PR will allow users to switch to server YUI from local, including combo, but the default configuration will be to load it from CDN. If you want to force to use YUI from local for development, or to be able to build html5apps and hybrid apps, you can use this setting:

{
    "settings": [ "environment:development" ],
    "staticHandling": {
        "serveYUIFromLocal": true
    }
}

Keep in mind that when using mojito build command, the combine flag should be set to false under yui.config because combo is not available in stand alone apps.

Other changes in this PR:

  • supporting html5app->forceRelativePaths for yui loader, making root and base to be relative when needed.
  • making default config.json a yaml file to add proper comments about default configurations.

TODO:

  • Update docs

…addon. making root and base for yui and app group to correlate. introducing staticHandling->serveYUIFromLocal configuration to disable serving yui from local app by default to preserve memory.
@caridy
Copy link
Contributor Author

caridy commented Feb 21, 2013

This is also suppose to fix issue #982.

@isao
Copy link
Contributor

isao commented Feb 21, 2013

(redacted)

@caridy
Copy link
Contributor Author

caridy commented Feb 21, 2013

@isao can you elaborate more?

@isao
Copy link
Contributor

isao commented Feb 21, 2013

@caridy made this gist to explain, before I saw the full context of the commit (I mistakenly thought you replaced the str.replace instead of adding a second one).

sorry, nm :)

👍

@imalberto
Copy link
Contributor

+1

caridy added a commit that referenced this pull request Feb 23, 2013
fixes #982. seed refactor to reduce memory allocation when YUI core modules should not be served from local server. Clear separation between YUI core modules and app-level modules (including synthetic modules). As part of the separation, the seed will have, at least, 2 files, YUI Core Seed + App Seed. Support for relative path when using mojito build command.
@caridy caridy merged commit 81a5bba into YahooArchive:develop Feb 23, 2013
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants