when livereload-url is specified, the development server is not started.
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 2/5
- Tempo estimado
- 1-3 horas
- Facilidade para iniciantes
- 25/100
- Tipo de issue
- Bug
- Clareza
- Claramente especificada
- Status de atividade
- Estagnada
- Stack de tecnologia
- typescript
- Domínio
- cli
Direção de pesquisa
Comece em packages/@ionic/cli/src/commands/capacitor/base.ts e inspecione runServe junto com as duas formas do comando no relatório. Reproduza o comando com --livereload-url e verifique se o servidor de desenvolvimento é iniciado enquanto a URL fornecida é usada; revise o pull request 5125 antes de começar, pois a issue relata que o trabalho já está em andamento.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
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
- Linguagem predominante
- TypeScript
- Estrelas
- 2k
- Forks
- 681
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
Guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de ionic-team/ionic-cli
-
triage
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 65/100
ionic-team/ionic-cli#5016 ·
-
ionic-cli development status Abertatriage
Dificuldade 5/5 Mais de uma semana Facilidade para iniciantes 15/100
ionic-team/ionic-cli#5131 ·
-
triage
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 56/100
ionic-team/ionic-cli#5130 ·
-
triage
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 72/100
ionic-team/ionic-cli#5129 ·
-
triage
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 42/100
ionic-team/ionic-cli#5127 · 2 comentários ·
Todas as issues de ionic-team/ionic-cli
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
[Bug]: Matrix progress drafts fail with "Matrix runtime not initialized" during tool activity Abertabug clawsweeper:linked-pr-open clawsweeper:needs-live-repro clawsweeper:no-new-fix-pr impact:message-loss issue-rating: 🐚 platinum hermit P2 regression
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
-
enhancement
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
-
calcite-components needs triage refactor
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
Esri/calcite-design-system#15203 ·
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 90/100
danielmiessler/LifeOS#2218 ·