@16bits/nes.css

中文文档
2.3.2发布于 2021/09/28MIT零依赖近 30 天下载 2.8万

since NES.css hasn't be published for a long time. this pkg is published with using the latest develop branch to solve some issues

原始使用文档
文档目录8 节
  1. Installation
  2. Styles
  3. Fonts
  4. Usage
  5. CSS Only
  6. Browser Support
  7. Copyright and license
  8. Development

since NES.css hasn't be published for a long time. this pkg is published with using the latest develop branch to solve some issues

NES.css is a NES-style(8bit-like) CSS Framework.

Gitter Commitizen friendly

Installation

Styles

NES.css is available via either npm (preferred), Yarn, or a CDN.

via package manager

npm install nes.css
# or
yarn add nes.css

Our package.json contains some additional metadata under the following keys:

  • sass - path to our main Sass source file
  • style - path to our non-minified CSS
AltCSS(sass, scss...)
// style.scss
@import "./node_modules/nes.css/css/nes.css"
JavaScript
// script.js
import "nes.css/css/nes.min.css";

You need to install css-loader.

HTML
<!-- index.html -->
<html>
  <head>
    <link rel="stylesheet" href="./node_modules/nes.css/css/nes.min.css">
  </head>
  <body></body>
</html>

via CDN

Import the CSS via a <link /> element:

<!-- minify -->
<link href="https://unpkg.com/[email protected]/css/nes.min.css" rel="stylesheet" />
<!-- latest -->
<link href="https://unpkg.com/nes.css@latest/css/nes.min.css" rel="stylesheet" />
<!-- core style only -->
<link href="https://unpkg.com/nes.css/css/nes-core.min.css" rel="stylesheet" />

Fonts

NES.css doesn't provide any fonts, but we do maintain the following list of fonts that we recommend for usage alongside the library.

LanguageFont
(Default)Press Start 2P
EnglishKongtext
Japanese美咲フォント
JapaneseNu もち
Korean둥근모꼴
ChineseZpix (最像素)

Usage

NES.css only provides components. You will need to define your own layout.

The recommended font for NES.css is Press Start 2P. However, Press Start 2P only supports English characters. When you're using this framework with any language other than English, please use another font. Follow the Google Fonts instructions about how to include them, or simply include it as below:

<head>
    <link href="https://fonts.googleapis.com/css?family=Press+Start+2P" rel="stylesheet">
    <link href="https://unpkg.com/nes.css/css/nes.css" rel="stylesheet" />

    <style>
      html, body, pre, code, kbd, samp {
          font-family: "font-family you want to use";
      }
    </style>
</head>

CSS Only

NES.css only requires CSS and doesn't depend on any JavaScript.

Browser Support

NES.css is compatible with the newest version of the following browsers:

  • Chrome
  • Firefox
  • Safari

Untested

  • IE/Edge

Code and documentation copyright 2018 B.C.Rikko. Code released under the MIT License. Docs released under Creative Commons.

Development

If you'd like to help us out with the project, we welcome contributions of all types! Check out our CONTRIBUTING.md for more details on how you can help make NES.css amazing!

版本与发布记录

@16bits/nes.css 共发布 2 个版本,首次发布于 2021/09/27;过去 12 个月发布了 0 个版本。

版本发布日期距今
2.3.2latest2021/09/285 年前
2.3.12021/09/275 年前

关于 @16bits/nes.css 的常见问题

@16bits/nes.css 是什么?

since NES.css hasn't be published for a long time. this pkg is published with using the latest develop branch to solve some issues

如何安装 @16bits/nes.css?

在项目目录运行 npm install @16bits/nes.css,或使用 pnpm add / yarn add / bun add。

@16bits/nes.css 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/16bits__nes.css 是否存在。

@16bits/nes.css 需要什么版本的 Node.js?

package.json 的 engines 字段要求 Node.js >=10.0.0。版本不符时 npm 默认只给出警告,开启 engine-strict 后会拒绝安装。

@16bits/nes.css 可以商用吗?

@16bits/nes.css 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@16bits/nes.css 的下载量有多少?

根据 npm 官方下载统计,@16bits/nes.css 在 2026/10/05 – 2026/11/03 这 30 天内被下载 28,378 次,日均约 946 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@16bits/nes.css 还在维护吗?

最新版本 2.3.2 发布于 2021/09/28(5 年前);至今共发布 2 个版本,其中过去 12 个月发布了 0 个;首次发布于 2021/09/27。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。