
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
主要目录结构
其中_func.scss中$rem默认100px,可设置覆盖
使用观察者模式管理状态切换
自定义观察者(observer)必须包含update方法,接收目标(subject)的当前状态和原状态。使用目标实例方法attach(), detach()管理观察者,参数接收(Observer|Array.<Observer>)。
const customObserver = () => ({
update(state, prevState) {
const { page: currentPage } = state;
const { page: prevPage } = prevState;
if (prevPage !== currentPage && currentPage === 'main') {
doSth();
}
},
});
const menu = new Menu('main');
menu.attach(customObserver());
menu添加自定义观察者示例。当menu状态切换到打开main页时将执行doSth函数。
浏览器支持情况
npx browserslist
见.browserslistrc
测试和文档
npm test
运行单元测试
npm run jsdoc
# darwin
npm run open
生成和查看doc
FAQs
UI
We found that zp-ui demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

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.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.