{"action":"created","issue":{"url":"https://api.github.com/repos/svaarala/duktape/issues/796","repository_url":"https://api.github.com/repos/svaarala/duktape","labels_url":"https://api.github.com/repos/svaarala/duktape/issues/796/labels{/name}","comments_url":"https://api.github.com/repos/svaarala/duktape/issues/796/comments","events_url":"https://api.github.com/repos/svaarala/duktape/issues/796/events","html_url":"https://github.com/svaarala/duktape/pull/796","id":156024228,"number":796,"title":"Add a Node.js-like module loader extra","user":{"login":"fatcerberus","id":4097841,"avatar_url":"https://avatars.githubusercontent.com/u/4097841?v=3","gravatar_id":"","url":"https://api.github.com/users/fatcerberus","html_url":"https://github.com/fatcerberus","followers_url":"https://api.github.com/users/fatcerberus/followers","following_url":"https://api.github.com/users/fatcerberus/following{/other_user}","gists_url":"https://api.github.com/users/fatcerberus/gists{/gist_id}","starred_url":"https://api.github.com/users/fatcerberus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fatcerberus/subscriptions","organizations_url":"https://api.github.com/users/fatcerberus/orgs","repos_url":"https://api.github.com/users/fatcerberus/repos","events_url":"https://api.github.com/users/fatcerberus/events{/privacy}","received_events_url":"https://api.github.com/users/fatcerberus/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":55,"created_at":"2016-05-20T18:31:57Z","updated_at":"2016-05-26T14:33:08Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/svaarala/duktape/pulls/796","html_url":"https://github.com/svaarala/duktape/pull/796","diff_url":"https://github.com/svaarala/duktape/pull/796.diff","patch_url":"https://github.com/svaarala/duktape/pull/796.patch"},"body":"A module loading framework and `require()` implementation based on Node.js.  Semantics match Node.js wherever possible and most features of the Node module system are provided.\r\n\r\nhttps://nodejs.org/api/modules.html\r\n\r\nFeatures:\r\n* Application provides callbacks to perform module resolution and loading\r\n* Module caching based on resolved module ID\r\n* Tolerates circular `require()` chains\r\n* Supports `module.exports`, `module.loaded`, and `module.require`\r\n* Supports `require.cache`\r\n* Supports `__filename` (but not `__dirname`)\r\n\r\nChecklist:\r\n- [x] Expose `duk__push_require_function()` to calling code? -> `duk_module_init()` registers a global `require`, so not needed\r\n- [x] Test harness to ensure correctness of all features such as `module.loaded`, `require.cache`, etc.\r\n- [x] Full documentation, in particular for callbacks\r\n- [x] More/better sanity checks/guards around callback invocations? -> tolerates superfluous values pushed by callbacks, any more is overkill\r\n- [x] Rename extra to `module-node`\r\n- [x] Match Node.js module ID semantics (`module.id === module.filename`)"},"comment":{"url":"https://api.github.com/repos/svaarala/duktape/issues/comments/221888537","html_url":"https://github.com/svaarala/duktape/pull/796#issuecomment-221888537","issue_url":"https://api.github.com/repos/svaarala/duktape/issues/796","id":221888537,"user":{"login":"svaarala","id":6377415,"avatar_url":"https://avatars.githubusercontent.com/u/6377415?v=3","gravatar_id":"","url":"https://api.github.com/users/svaarala","html_url":"https://github.com/svaarala","followers_url":"https://api.github.com/users/svaarala/followers","following_url":"https://api.github.com/users/svaarala/following{/other_user}","gists_url":"https://api.github.com/users/svaarala/gists{/gist_id}","starred_url":"https://api.github.com/users/svaarala/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/svaarala/subscriptions","organizations_url":"https://api.github.com/users/svaarala/orgs","repos_url":"https://api.github.com/users/svaarala/repos","events_url":"https://api.github.com/users/svaarala/events{/privacy}","received_events_url":"https://api.github.com/users/svaarala/received_events","type":"User","site_admin":false},"created_at":"2016-05-26T14:33:08Z","updated_at":"2016-05-26T14:33:08Z","body":"Also a releases entry is needed, I can add that separately if you wish."}}
{"actor":{"display_login":"svaarala"}}