{"action":"created","issue":{"url":"https://api.github.com/repos/SlexAxton/require-handlebars-plugin/issues/238","labels_url":"https://api.github.com/repos/SlexAxton/require-handlebars-plugin/issues/238/labels{/name}","comments_url":"https://api.github.com/repos/SlexAxton/require-handlebars-plugin/issues/238/comments","events_url":"https://api.github.com/repos/SlexAxton/require-handlebars-plugin/issues/238/events","html_url":"https://github.com/SlexAxton/require-handlebars-plugin/pull/238","id":104565850,"number":238,"title":"Allow users to configure hbs to use handlebars in an alternate location","user":{"login":"kworth","id":407644,"avatar_url":"https://avatars.githubusercontent.com/u/407644?v=3","gravatar_id":"","url":"https://api.github.com/users/kworth","html_url":"https://github.com/kworth","followers_url":"https://api.github.com/users/kworth/followers","following_url":"https://api.github.com/users/kworth/following{/other_user}","gists_url":"https://api.github.com/users/kworth/gists{/gist_id}","starred_url":"https://api.github.com/users/kworth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kworth/subscriptions","organizations_url":"https://api.github.com/users/kworth/orgs","repos_url":"https://api.github.com/users/kworth/repos","events_url":"https://api.github.com/users/kworth/events{/privacy}","received_events_url":"https://api.github.com/users/kworth/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-09-02T20:34:32Z","updated_at":"2015-09-02T21:39:12Z","closed_at":"2015-09-02T20:35:52Z","pull_request":{"url":"https://api.github.com/repos/SlexAxton/require-handlebars-plugin/pulls/238","html_url":"https://github.com/SlexAxton/require-handlebars-plugin/pull/238","diff_url":"https://github.com/SlexAxton/require-handlebars-plugin/pull/238.diff","patch_url":"https://github.com/SlexAxton/require-handlebars-plugin/pull/238.patch"},"body":"For apps that currently have handlebars defined in a location other than\r\nan hbs directory at the root of the project, this will allow them to\r\nensure that hbs uses the handlebars they need. (example usage below)\r\n\r\nThe key here is that when you try to bring in handlebars more than once,\r\nthings seem to become very broken. You either end up with modules using\r\nhandlebars instance A where the helper was registered on instance B, or\r\nthe modules are using the shorthand \"handlebars\" and hbs is using the\r\nspecified path \"hbs/handlebars\" and then require.js gets confused.\r\nTherefore, this new config option allows a project with many modules\r\nalready using the shorthand to stay the same, instead of having to change\r\neach one of them to start using the same path that hbs is using.\r\n\r\n```javascript\r\nrequire.config({\r\n    paths: {\r\n        \"handlebars\": \"some/path/to/handlebars\" // shorthand\r\n\t}\r\n...\r\n```\r\n\r\nExample usage:\r\n\r\n```javascript\r\n\"hbs\": {\r\n    \"handlebarsPath\": \"handlebars\",\r\n    \"helperDirectory\": \"some/path/for/templates/helpers/\"\r\n}\r\n```"},"comment":{"url":"https://api.github.com/repos/SlexAxton/require-handlebars-plugin/issues/comments/137252139","html_url":"https://github.com/SlexAxton/require-handlebars-plugin/pull/238#issuecomment-137252139","issue_url":"https://api.github.com/repos/SlexAxton/require-handlebars-plugin/issues/238","id":137252139,"user":{"login":"kworth","id":407644,"avatar_url":"https://avatars.githubusercontent.com/u/407644?v=3","gravatar_id":"","url":"https://api.github.com/users/kworth","html_url":"https://github.com/kworth","followers_url":"https://api.github.com/users/kworth/followers","following_url":"https://api.github.com/users/kworth/following{/other_user}","gists_url":"https://api.github.com/users/kworth/gists{/gist_id}","starred_url":"https://api.github.com/users/kworth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kworth/subscriptions","organizations_url":"https://api.github.com/users/kworth/orgs","repos_url":"https://api.github.com/users/kworth/repos","events_url":"https://api.github.com/users/kworth/events{/privacy}","received_events_url":"https://api.github.com/users/kworth/received_events","type":"User","site_admin":false},"created_at":"2015-09-02T21:39:12Z","updated_at":"2015-09-02T21:39:12Z","body":"Sweet!"}}