when livereload-url is specified, the development server is not started.
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 25/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Stale
- Tech stack
- typescript
- Domain
- cli
Research direction
Start in packages/@ionic/cli/src/commands/capacitor/base.ts and inspect runServe alongside the two command forms in the report. Reproduce the command with --livereload-url and verify that the development server starts while the supplied URL is used; review pull request 5125 before beginning because the issue reports work already underway.
Written by the indexing model from the issue text.
Description
Description:
with this command "ionic capacitor run android -l --external --host=192.168.7.78 --port=8021" the development server will be started. everything goes well. app will use http://192.168.7.78:8021/ to access the web app.
but with this command "ionic capacitor run android -l --external --host=192.168.7.78 --port=8021 --livereload-url=http://192.168.7.78:8021", the development serve does not start.
why do I want to specify host & port & the url? for whatever reason, my reality is that the android is connected to a "different" network, and there is some mapping, so even the livereload-url=https://x.y.z/(different IP, DNS or not, and even https), it will be mapped to http://192.168.7.78:8021.
Steps to Reproduce:
so simple, so need big effort.
Output:
so simple, no need
My ionic info:
Other Information:
To fix:
https://github.com/ionic-team/ionic-cli/blob/develop/packages/%40ionic/cli/src/commands/capacitor/base.ts
inside runServe function
let serverUrl = options['livereload-url'] ? String(options['livereload-url']) : undefined;
if (!serverUrl) {
const details = await runner.run(runnerOpts); //*********
serverUrl = `${details.protocol || 'http'}://${details.externalAddress}:${details.port}`;
}
we just have to move the ***** line out of the if statement, then everything is Okay. If I am wrong, please inform me.
If this is the right solution, then I made a pull request 5125: https://github.com/ionic-team/ionic-cli/pull/5125
- Dominant language
- TypeScript
- Stars
- 2k
- Forks
- 681
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from ionic-team/ionic-cli
-
triage
Difficulty 1/5 Under an hour Newbie friendliness 65/100
ionic-team/ionic-cli#5016 ·
-
triage
Difficulty 5/5 Over a week Newbie friendliness 15/100
ionic-team/ionic-cli#5131 ·
-
triage
Difficulty 3/5 1-2 days Newbie friendliness 56/100
ionic-team/ionic-cli#5130 ·
-
triage
Difficulty 3/5 1-2 days Newbie friendliness 72/100
ionic-team/ionic-cli#5129 ·
-
triage
Difficulty 3/5 1-2 days Newbie friendliness 42/100
ionic-team/ionic-cli#5127 · 2 comments ·
All issues in ionic-team/ionic-cli
Similar issues
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
dennys-bd/agent-hive#184 ·
-
Add: hunch Open
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
AbdelStark/awesome-typesafe#104 ·
-
ai-observability bug team/ai-observability
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
vicharanashala/fln#563 ·