{"id":17772731,"url":"https://github.com/jamesplease/babel-module-inconsistency","last_synced_at":"2025-04-01T15:21:29.198Z","repository":{"id":66133727,"uuid":"48707512","full_name":"jamesplease/babel-module-inconsistency","owner":"jamesplease","description":"This demonstrates the behavior of the es2015 modules=\u003eCJS transform for Babel","archived":false,"fork":false,"pushed_at":"2015-12-28T19:10:56.000Z","size":3,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-07T09:42:01.514Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jamesplease.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-12-28T18:57:43.000Z","updated_at":"2023-03-10T08:28:26.000Z","dependencies_parsed_at":"2023-02-20T00:00:49.078Z","dependency_job_id":null,"html_url":"https://github.com/jamesplease/babel-module-inconsistency","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jamesplease%2Fbabel-module-inconsistency","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jamesplease%2Fbabel-module-inconsistency/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jamesplease%2Fbabel-module-inconsistency/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jamesplease%2Fbabel-module-inconsistency/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jamesplease","download_url":"https://codeload.github.com/jamesplease/babel-module-inconsistency/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246660086,"owners_count":20813339,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-26T21:40:34.923Z","updated_at":"2025-04-01T15:21:29.178Z","avatar_url":"https://github.com/jamesplease.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"Babel 6.1.2 appears to have an inconsistency in how it transpiles ES2015\nmodules to CommonJS, specifically when the exported module uses\n`export default`.\n\nThis example involves the module `test.js`, which is a simple file that\nexports a string as the default value.\n\nThere are two behaviors that this repository shows.\n\n### Correct behavior\n\nThe module should be exported as:\n\n```js\n{\n  default: \"foo\"\n}\n```\n\nThis is observed when the source file is transpiled with the `babel` CLI\ncommand.\n\nA handy shortcut to observe this is to run `npm run babel-compile`.\n\n### Incorrect behavior\n\nThe module is exported as:\n\n```js\n\"foo\"\n```\n\nThis can be observed in two ways: using `babel-node` or using `babel-register`.\n\nThere are two shortcuts for running this:\n\n- `npm run babel-node`\n- `npm run babel-register`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjamesplease%2Fbabel-module-inconsistency","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjamesplease%2Fbabel-module-inconsistency","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjamesplease%2Fbabel-module-inconsistency/lists"}