As widely acknowledged, the sample app won't run in browser or under ionic serve.
Obviously one of the major strengths of Ionic is the 'write once deploy anywhere concept'.
Any chance you could publish a sample app that is also compatible with browser/web running, e.g. one that switches to a non PKCE auth method when operating in browser?