{"action":"created","issue":{"url":"https://api.github.com/repos/apparatus/mu/issues/31","repository_url":"https://api.github.com/repos/apparatus/mu","labels_url":"https://api.github.com/repos/apparatus/mu/issues/31/labels{/name}","comments_url":"https://api.github.com/repos/apparatus/mu/issues/31/comments","events_url":"https://api.github.com/repos/apparatus/mu/issues/31/events","html_url":"https://github.com/apparatus/mu/issues/31","id":183164100,"number":31,"title":"use es2040 for browserify transform and linting","user":{"login":"davidmarkclements","id":1190716,"avatar_url":"https://avatars.githubusercontent.com/u/1190716?v=3","gravatar_id":"","url":"https://api.github.com/users/davidmarkclements","html_url":"https://github.com/davidmarkclements","followers_url":"https://api.github.com/users/davidmarkclements/followers","following_url":"https://api.github.com/users/davidmarkclements/following{/other_user}","gists_url":"https://api.github.com/users/davidmarkclements/gists{/gist_id}","starred_url":"https://api.github.com/users/davidmarkclements/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidmarkclements/subscriptions","organizations_url":"https://api.github.com/users/davidmarkclements/orgs","repos_url":"https://api.github.com/users/davidmarkclements/repos","events_url":"https://api.github.com/users/davidmarkclements/events{/privacy}","received_events_url":"https://api.github.com/users/davidmarkclements/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-10-14T22:30:18Z","updated_at":"2016-10-15T11:36:01Z","closed_at":null,"body":"https://www.npmjs.com/package/es2040\r\n\r\nThis enforces a subset of *useful* ES6 features and prevents the others by matter of course\r\n\r\nTranspiles this es6 subset for older browsers (obviously faster because it's more focused)\r\n\r\nNo need for a server side transpile step - all of es2040 is supported in v6\r\n\r\nIt could be useful to figure out a way to make it a secondary linter (after standard) - maybe start with something simple as attempting to transpile and then \"oops that's not es2040\"\r\n\r\nES2040 supported features:\r\n\r\n- `fat arrows` - make inline functions cute-looking\r\n- `template strings` / `tagged templates` - enable DSLs inside of JS\r\n- `const` - using `const` by default makes it easy to spot where values are\r\n  being redeclared\r\n- `object destructuring` - `const { a, b } = { a: 1, b: 2 }`\r\n- `array destructuring` - `const [a, b] = [1, 2]`\r\n- `default parameters` - `({ a = 1, b = 2 } = {}) => a`\r\n- `rest parameters` - `(a, b, ...args) => {}`\r\n- `spread literals` - `f(a, b, ...args)`\r\n- `short-hand properties` - `return { a, b }`\r\n- `computed properties` - `return { [a]: b }`\r\n\r\nIf we want to be even more strict, we could go with ES2020 is:\r\n\r\n- `fat arrows` - make inline functions cute-looking\r\n- `template strings` / `tagged templates` - enable DSLs inside of JS\r\n- `const` - using `const` by default makes it easy to spot where values are\r\n  being redeclared\r\n\r\nWhich would be probably be wicked fast at transpiling.\r\n\r\nIn either case, much faster than babel.\r\n\r\nThoughts? @mcdonnelldean @lucamaraschi @mcdonnelldean @mcollina "},"comment":{"url":"https://api.github.com/repos/apparatus/mu/issues/comments/253979012","html_url":"https://github.com/apparatus/mu/issues/31#issuecomment-253979012","issue_url":"https://api.github.com/repos/apparatus/mu/issues/31","id":253979012,"user":{"login":"davidmarkclements","id":1190716,"avatar_url":"https://avatars.githubusercontent.com/u/1190716?v=3","gravatar_id":"","url":"https://api.github.com/users/davidmarkclements","html_url":"https://github.com/davidmarkclements","followers_url":"https://api.github.com/users/davidmarkclements/followers","following_url":"https://api.github.com/users/davidmarkclements/following{/other_user}","gists_url":"https://api.github.com/users/davidmarkclements/gists{/gist_id}","starred_url":"https://api.github.com/users/davidmarkclements/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidmarkclements/subscriptions","organizations_url":"https://api.github.com/users/davidmarkclements/orgs","repos_url":"https://api.github.com/users/davidmarkclements/repos","events_url":"https://api.github.com/users/davidmarkclements/events{/privacy}","received_events_url":"https://api.github.com/users/davidmarkclements/received_events","type":"User","site_admin":false},"created_at":"2016-10-15T11:36:01Z","updated_at":"2016-10-15T11:36:01Z","body":"In that case (v4 support) we could still go with es2020, at least have const, template strings and fat arrows, and add es2020 as browserify transform in package.json - when a user browserifies at the app level browserify will know to use es2020 transform for our lib. This can be independent of their choice to transpile. \r\n\r\nBut it may be a bit too much of an investment (figuring out usage edge cases) to justify the three features. Template strings is mainly what I'm wanting "}}
{"actor":{"display_login":"davidmarkclements"}}