ionic-team / ionic-team/capacitor-docs
npx cap add ios produces a warning unless you run `npm run build` first
- Dominant language
- MDX
- Stars
- 48
- Forks
- 792
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 4
Description
URL: https://capacitorjs.com/docs/getting-started
I'm following the getting-started instructions:
https://capacitorjs.com/docs/getting-started
If I run:
```
npm i @capacitor/android @capacitor/ios
npx cap add ios
```
I get an warning:
➜ share-target-vibes npx cap add ios
✔ Adding native Xcode project in ios in 12.10ms
✔ add in 12.36ms
[warn] sync could not run--missing dist directory.
[success] ios platform added!
Follow the Developer Workflow guide to get building:
https://capacitorjs.com/docs/basics/workflow
It would be helpful to update the docs to state that you should run `npm run build` at least once to avoid this warning:
> After the Capacitor core runtime is installed, you can install the Android and iOS platforms.
>
> `npm i @capacitor/android @capacitor/ios
>
> Once the platforms have been added to your package.json, you should run `npm run build` at least once to create the web app build directory. You can run the following commands to create your Android and iOS projects for your native application.
>
> `npx cap add android`
> `npx cap add ios`
Contributor guide
Assessment
This issue has not been assessed yet.