New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

computer-modern

Package Overview
Dependencies
Maintainers
0
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

computer-modern

An NPM package containing the OFL-licensed Computer Modern fonts, and CSS @font-face declarations for them.

  • 0.1.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1.4K
increased by12.93%
Maintainers
0
Weekly downloads
 
Created
Source

Computer Modern Webfonts

This is an NPM package that contains the Computer Modern fonts in webfont format (WOFF2 and TTF, because modern browsers don't really need much else).

Licensing and Attribution

The Computer Modern fonts are licensed under the SIL Open Font License. See the SIL Open Font License for details. This package merely provides the fonts in a different format, and is not a derivative work. The original font files can be downloaded from SourceForge.

Usage

This package breaks the fonts down based on family. The most common one is CMU Serif.

/* Import all Computer Modern fonts */
@import "computer-modern/index.css";

/* Import individual families */
@import "computer-modern/cmu-bright.css";
@import "computer-modern/cmu-classical-serif.css";
@import "computer-modern/cmu-concrete.css";
@import "computer-modern/cmu-sans-serif-demi-condensed.css";
@import "computer-modern/cmu-sans-serif.css";
@import "computer-modern/cmu-serif-extra.css";
@import "computer-modern/cmu-serif-upright-italic.css";
@import "computer-modern/cmu-serif.css"; /* ← most common! */
@import "computer-modern/cmu-typewriter-text-variable-width.css";
@import "computer-modern/cmu-typewriter-text.css";

Depending on what fonts you import, you can use them like this:

.example-selector {
  font-family: "CMU Bright";
  font-family: "CMU Classical Serif";
  font-family: "CMU Concrete";
  font-family: "CMU Sans Serif";
  font-family: "CMU Sans Serif Demi Condensed";
  font-family: "CMU Serif";
  font-family: "CMU Serif Extra";
  font-family: "CMU Serif Upright Italic";
  font-family: "CMU Typewriter Text";
  font-family: "CMU Typewriter Text Variable Width";
}

Keywords

FAQs

Package last updated on 14 Oct 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc