npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

create-qunit

v2.0.1

Published

A quick and simple way to setup and run qunit test in browser

Downloads

6

Readme

create-qunit

在浏览器和 node 中运行快速简便的 Qunit 测试套件

English README

为什么?因为我认为大部分的浏览器测试套件是垃圾!

我只是想快速测试一个想法,设置浏览器测试套件的时间是荒谬的!!! 最糟糕的部分是 - 我经常发现自己调试f**king,一堆屎工具,然后实际处理我的代码...

qunit 存在很长一段时间, 简单, 但猜猜什么 - 它无毛病!

安装

$ npx create-qunit@latest 

$ npm init qunit

配置

安装后,您应该在项目根上找到一个 qunit 文件夹。在里面你应该找到一个 run-qunit.js 文件。在这里您可以编辑配置选项。

此外,它会将一个脚本插入到您的 package.json, 你可以只运行 npm run qunit 看看会发生什么。

选项

设置基本目录 --baseDir

您可以通过传递 --baseDir 来设置放置 qunit 文件夹的位置

$ npx create-qunit --baseDir ./tests

然后,qunit 文件夹和所有关联文件将位于 ./tests/qunit

额外 根目录 (webroot)

您可以在设置期间(并且应该)添加额外根目录。

$ npx create-qunit ./dist

它们将添加到配置选项的 webroot 中,当开发人员服务器启动时,它们就会得到服务。 然后,您只需要编辑 index.html 添加您的代码。

例如,您正在处理一个称为 awesome-script 的项目,您的分发代码位于 dist/awesome-script.js 中。

然后只需将其添加到index.html

<script src="/awesome-script.js"></script>

原因是 webroot 指向 dist,然后为文件所在的浏览器提供内容。

跳过安装 --skipInstall

~~在安装结束时,它将运行 npm install 以添加额外的依赖项。如果您不需要,可以添加 --skipInstall~~

server-io-core 附加配置

您可以使用 server-io-core 设置更多选项。特别是 当您需要服务器端代码来测试您的 javascript 代码时。您可以使用代理选项。


ISC

Joel Chu

NEWBRAN LTD (c) 2022

TO1SOURCE