Skip to content

Help setting up typography #5597

Answered by asyncLiz
nboisnea asked this question in Q&A
Apr 23, 2024 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

Hi! Sorry for the slow response. I put a reproduction of this issue in a jsbin, which seems to work.

The last script your posted is the right way to set up typography, but it needs to be part of the build process. I think it might be outside of your index.js file since it's in <script> tags. If you move those two lines within the <script> into your index.js file and re-build, I think that will fix your issue.

Two extra things I noticed:

  • You're importing outlined-text-field.js in your script but using <md-filled-text-field> in your html.
  • You don't need import '@material/web/typography/md-typescale-styles.js'; in your index.js. Importing that file won't perform side-effects. You need to im…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@nboisnea
Comment options

Answer selected by nboisnea
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants