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

generator-espm-plugin

v1.2.1

Published

Yeoman generator para gerar plugins para o projeto 'ES na palma da mão'

Downloads

14

Readme

generator-espm-plugin

[![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency Status][daviddm-image]][daviddm-url] [![Coverage percentage][coveralls-image]][coveralls-url]

Yeoman generator para gerar plugins para o projeto ES na palma da mão usando jspm.

##1. Instale generator-espm-plugin e dependências:

Primeiro, instale yeoman, jspm CLI, jspm Server e então generator-espm-plugin usando npm (assumindo que você tem node.js e npm instalados).

npm i -g yo jspm jspm-server generator-espm-plugin

###2. Crie um novo diretório para o plugin:

mkdir meu-plugin & cd meu-plugin

Opcionalmente bloqueie a versão do jspm para o projeto:

cd meu-plugin
npm install jspm --save-dev

É aconselhável instalar jspm localmente para bloquear a versão do jspm para o plugin. Essa medida garante que eventuais atualizações ao jspm global não interfiram no comportamento do plugin. Use jspm -v para ver a versão local instalada.

###3. Gere um novo plugin: Execute generator-espm-plugin dentro do diretório criado, opcionalmente informando o nome do plugin:

yo espm-plugin [nome do plugin]

Se o nome do plugin não for informado, o nome do plugin será o nome do diretório onde o generator está sendo executado.

###4. Responda às perguntas do generator O generator fará as seguintes perguntas:

Pergunta: Por favor digite seu username do Github:

Digite seu nome de usuário do GitHub (obrigatório), o qual será usado para configurar o jspm.

Pergunta: Deseja executar o plugin imediatamente após a instalação? (Yn)

Responda sim (Y ou y) para iniciar um servidor local, abrir uma janela do browser e exibir o recém-criado plugin imediatamente após a instalação.

Repare que generator-espm-plugin emula uma versão de desenvolvimento lightweight da aplicação ES na palma da mão e executa o plugin no contexto dessa aplicação.

Pergunta: Qual o "module system" usado pelo plugin?

Selecione ES6 para usar a sintaxe e o sistema de módulos do ECMAScript 2015 ou selecione CommonJS para usar o sistema de módulos CommonJS, como usado tradicionalmente usado no módulos do node.js. Indepentemente do sistema de módulos escolhido, o conjunto jspm + systemjs vai fazer a requisição assíncrona dos seus scripts dentro do seu plugin à medida que você os requisitar, seja através de require(xxxx) (CommonJS) ou import xxx from 'XXXXX' (ES6).

Pergunta: Deseja criar unit tests?

Escolha sim (Y ou y) para gerar configurações de teste e testes unitários de exemplo para o plugin.

###4. Instale packages a partir dos seguintes registros: jspm, GitHub ou npm: Exemplos:

jspm install jquery
jspm install myname=npm:underscore
jspm install github:components/jquery
jspm install npm:lodash-node

##Tooling Abaixo seguem breves descrições das ferramentas utilizadas no projeto:

  • yeoman é uma ferramenta de scaffolding de aplicações web modernas.
  • jspm CLI é um package manager para o browser.
  • jspm Server é um servidor local que será usado para rodar seu plugin em desenvolvimento.

##Workflow em desenvolvimento

###JSPM linking (com watching)

gulp link

###Deploy de uma nova versão para o Github.

gulp deploy

Este comando irá criar um tagged commit seguido de push para o repositório do plugin no Github.

Leia mais sobre Yeoman sobre Yeoman.

License

MIT © PRODEST [npm-image]: https://badge.fury.io/js/generator-espm-plugin.svg [npm-url]: https://badge.fury.io/js/generator-espm-plugin [travis-image]: https://travis-ci.org/prodest/generator-espm-plugin.svg [travis-url]: https://travis-ci.org/prodest/generator-espm-plugin [daviddm-image]: https://david-dm.org/prodest/generator-espm-plugin.svg?theme=shields.io [daviddm-url]: https://david-dm.org/prodest/generator-espm-plugin [coveralls-image]: https://coveralls.io/repos/prodest/generator-espm-plugin/badge.svg [coveralls-url]: https://coveralls.io/r/prodest/generator-espm-plugin