{"id":13394193,"url":"https://github.com/ericvicenti/create-react-workspace","last_synced_at":"2025-04-30T07:06:19.749Z","repository":{"id":146807339,"uuid":"90521529","full_name":"ericvicenti/create-react-workspace","owner":"ericvicenti","description":"Develop and share code between React web apps, React Native apps, and standalone libraries/components.","archived":false,"fork":false,"pushed_at":"2017-07-09T13:00:33.000Z","size":32,"stargazers_count":86,"open_issues_count":5,"forks_count":8,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-04-30T07:06:14.442Z","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/ericvicenti.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,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-05-07T09:19:59.000Z","updated_at":"2024-03-21T17:12:05.000Z","dependencies_parsed_at":"2023-03-30T09:09:39.667Z","dependency_job_id":null,"html_url":"https://github.com/ericvicenti/create-react-workspace","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/ericvicenti%2Fcreate-react-workspace","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericvicenti%2Fcreate-react-workspace/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericvicenti%2Fcreate-react-workspace/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericvicenti%2Fcreate-react-workspace/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ericvicenti","download_url":"https://codeload.github.com/ericvicenti/create-react-workspace/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251658208,"owners_count":21622819,"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-07-30T17:01:12.055Z","updated_at":"2025-04-30T07:06:19.728Z","avatar_url":"https://github.com/ericvicenti.png","language":"JavaScript","readme":"# Create React Workspace\n\nDevelop and share code between React web apps, React Native apps, and standalone libraries/components.\n\n\u003e Warning: This is a super early alpha and anything could break. Please provide feedback and consider jumping into the code and contributing!\n\nUnder the hood, this uses create-react-app, and react-native-cli, although the dependencies may change over time.\n\n## Create a new workspace\n\n```\nnpm install -g create-react-workspace\ncd ~\ncreate-react-workspace dev\ncd dev\n# Optionally, `git init`\n```\n\n## Create a web app\n\n```\nnpm run create-web-app my-web-app\n# The app will be created in ~/dev/my-web-app\n```\n\nAt this point, you can `cd my-web-app` and run `npm start` or anything else that `create-react-app` supports.\n\nIf you want to develop the app alongside local dependencies, you can:\n\n```\ncd ~/dev\nnpm start my-web-app\n# The app will run, as well as the packager for the app's local dependencies\n```\n\n## Create a native app\n\n```\nnpm run create-native-app my-native-app\n# The app will be created in my-native-app\ncd my-native-app\nnpm run ios\nnpm run android\n```\n\nAt this point, you can `cd ~/dev/my-native-app` and run `react-native run-ios`, `react-native run-android` or anything else that `react-native` supports.\n\nIf you want to develop the app alongside local dependencies, you can:\n\n```\ncd ~/dev\nnpm start my-native-app\n# The dev server will run, as well as the packager for the app's local dependencies\n```\n\n## Create a local library for shared code\n\nIf you want to share JS logic or components between several apps:\n\n```\nnpm run create-library my-library\n# The library will be created in ~/dev/my-library\n```\n\nNow you can `cd ~/dev/my-library` and run `npm build` and `npm test` to develop the library.\n\n### Link a local library into an app\n\nIf you want to use the library from other packages in the workspace:\n\nAdd the dependency to `~/dev/my-web-app/package.json` or `~/dev/my-native-app/package.json`\n```\n ...\n \"dependencies\": {\n   \"my-library\": \"0.0.1\",\n   ...\n```\n\nNow, from `~/dev`, run:\n\n```\nnpm run bootstrap\n```\n\n### Run and develop an app\n\nTo run an app and all the bootstraped dependencies:\n\n```\nnpm start my-native-app my-web-app\n# both apps will start, and they will handle changes from my-library any other local dependencies!\n```\n\n## Help Wanted!\n\nSubmit an issue to let us know what you're up to, and get to work! The following improvements would be rapidly accepted:\n\n- Windows support\n- Jest tests\n- Prettier\n- Flow\n- Eject ala create-react-app\n- Upgrade ala create-react-app\n- Refactor: directly integrate with create-react-app and react-native-init\n- Support create-react-native-app. Blocked by current usage of Haul\n- Upgrade to RN 0.44. Blocked by brokenness of Haul on Android\n- e2e tests for the workspace\n- Improved errors and docs\n- Split out create-library and create-component\n- Add storybook support to create-component\n\nThese roadmap items are more complicated, so please open issues to discuss:\n\n- Switch to react-primitives for library dependency, rather than react-dom+react-native+react-native-web\n- Either improve integration of haul/webpack for React Native, or use the React Native packager for symlinks+web\n- Support publishing and release workflows\n","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fericvicenti%2Fcreate-react-workspace","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fericvicenti%2Fcreate-react-workspace","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fericvicenti%2Fcreate-react-workspace/lists"}