Quantcast
Channel: Ionic Forum - Latest topics
Viewing all articles
Browse latest Browse all 70432

How to build index.html with custom title and base href

$
0
0

@MarkL wrote:

Ionic 4. CLI version 6.9.1

After running “ionic build --prod” the index.html file in our www folder looks like this:

<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="utf-8" />
  <title>Ionic App</title>

  <base href="/" />

How do we configure our build scripts to change the title and base href? I haven’t found anything about the title, but for base href I’ve tried a couple of suggestions, none have worked though:

ionic build --prod --base-href=/ui/
ionic build --prod --base-href /ui/
ionic build --prod -- --base-href=/ui/
ionic build --prod -- --base-href /ui/
ionic build --prod --base-href="/ui/"
ionic build --prod --base-href "/ui/"
ionic build --prod -- --base-href="/ui/"
ionic build --prod -- --base-href "/ui/"

We aren’t building using Cordova because we are running as a PWA.

I suppose I can run a post build script to overwrite the title and base href in index.html, but surely there’s a way to do this within ionic that I’m missing.

Posts: 2

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 70432

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>