{"action":"created","issue":{"url":"https://api.github.com/repos/meteor/meteor/issues/6222","repository_url":"https://api.github.com/repos/meteor/meteor","labels_url":"https://api.github.com/repos/meteor/meteor/issues/6222/labels{/name}","comments_url":"https://api.github.com/repos/meteor/meteor/issues/6222/comments","events_url":"https://api.github.com/repos/meteor/meteor/issues/6222/events","html_url":"https://github.com/meteor/meteor/issues/6222","id":133111594,"number":6222,"title":"Add new target: web.worker","user":{"login":"mitar","id":585279,"avatar_url":"https://avatars.githubusercontent.com/u/585279?v=3","gravatar_id":"","url":"https://api.github.com/users/mitar","html_url":"https://github.com/mitar","followers_url":"https://api.github.com/users/mitar/followers","following_url":"https://api.github.com/users/mitar/following{/other_user}","gists_url":"https://api.github.com/users/mitar/gists{/gist_id}","starred_url":"https://api.github.com/users/mitar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mitar/subscriptions","organizations_url":"https://api.github.com/users/mitar/orgs","repos_url":"https://api.github.com/users/mitar/repos","events_url":"https://api.github.com/users/mitar/events{/privacy}","received_events_url":"https://api.github.com/users/mitar/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/meteor/meteor/labels/feature","name":"feature","color":"02d7e1"},{"url":"https://api.github.com/repos/meteor/meteor/labels/Project:Isobuild","name":"Project:Isobuild","color":"f7c6c7"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":28,"created_at":"2016-02-11T23:06:22Z","updated_at":"2016-06-09T14:33:23Z","closed_at":null,"body":"***1 Upvote*** This is a ticket to discuss one idea I implemented elsewhere and would like to bring it into the Meteor core.\r\n\r\nI would like to add new target `web.worker` to the Meteor. This would allow one to use the whole toolchain (ecmascript, coffeescript, combining multiple packages) for various web workers (web workers, service workers, etc.). This would address the following issues: https://github.com/meteor/meteor/issues/5982 https://github.com/meteor/meteor/issues/2751\r\n\r\nI have the code ready in my fork and works pretty nice.\r\n\r\nIs this something I should make a pull request? What would be guidelines and design considerations here?\r\n\r\nOne open issue related to this is, that once you have this, some such feature is needed: https://github.com/meteor/meteor/issues/6099 My current plan to address this to add `api.onUseDependices({target: [listOfDependingTargets]})` which would register that when somebody depends on the package with `target`, also `listOfDependingTargets` should be added.\r\n\r\nThis allows one to depend a package only for `web.browser`, but would pull in also `web.worker` because it is used internally.\r\n\r\nThe other thing which is needed is something like https://github.com/meteor/meteor/issues/6203, which allows one to dynamically resolves dependencies. So if I do `importScripts('packages/ejson.js')` this will automatically pull also `packages/base64.js` as a dependency, for example. Works pretty well for both workers and `<script>` tags in my implementation.\r\n\r\nThis pull request https://github.com/meteor/meteor/pull/5714 should probably also be pulled in to get manifest file have correct URLs for content. In this way then one does not have to hard-code URLs to workers' scripts, but can read manifest and resolve them (I would not provide mechanism for resolving as part of this pull request, but it can be done later on)."},"comment":{"url":"https://api.github.com/repos/meteor/meteor/issues/comments/224913518","html_url":"https://github.com/meteor/meteor/issues/6222#issuecomment-224913518","issue_url":"https://api.github.com/repos/meteor/meteor/issues/6222","id":224913518,"user":{"login":"danlg","id":12525045,"avatar_url":"https://avatars.githubusercontent.com/u/12525045?v=3","gravatar_id":"","url":"https://api.github.com/users/danlg","html_url":"https://github.com/danlg","followers_url":"https://api.github.com/users/danlg/followers","following_url":"https://api.github.com/users/danlg/following{/other_user}","gists_url":"https://api.github.com/users/danlg/gists{/gist_id}","starred_url":"https://api.github.com/users/danlg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danlg/subscriptions","organizations_url":"https://api.github.com/users/danlg/orgs","repos_url":"https://api.github.com/users/danlg/repos","events_url":"https://api.github.com/users/danlg/events{/privacy}","received_events_url":"https://api.github.com/users/danlg/received_events","type":"User","site_admin":false},"created_at":"2016-06-09T14:33:23Z","updated_at":"2016-06-09T14:33:23Z","body":"Yes offline support with standard W3C technology is much better than 3rd party solution (e.g. ground db). However, to build cross platform app is there a way to have this wprking on Android and iOS. I'm confused because it is not supported on Safari but I found this plugin from Google Chromium team\r\n\r\nhttps://github.com/MobileChromeApps/cordova-plugin-service-worker\r\n"}}
{"actor":{"display_login":"danlg"}}