DEV Community


Posted on

Poi 11 alpha 18

I just released Poi 11 alpha 18 which might be the last "alpha" release.

You can now get started and create a new project like this:

npm i -g create-poi-app@next
create-poi-app my-app
Enter fullscreen mode Exit fullscreen mode

Or for one-off use:

npx create-poi-app@next my-app
Enter fullscreen mode Exit fullscreen mode

Note that all our version 11 packages are published under @next channel on npm for now.

2018-09-20 11 50 33

If you select all the defaults, the above command will generate a minimal project in my-app folder:

├── package.json
├── poi.config.js
├── public
│   └── favicon.ico
├── src
│   ├── components
│   │   └── App.js
│   └── index.js
└── yarn.lock
Enter fullscreen mode Exit fullscreen mode

The poi.config.js so far is really simple, here we need to use src/index.js instead of the default index.js as app entry:

// poi.config.js
module.exports = {
  entry: 'src/index.js'
Enter fullscreen mode Exit fullscreen mode

Inside the newly created project, there're also some built-in npm scripts you can run:

  • yarn start: Calls poi dev command to start a development server to run your app.
  • yarn build: Calls poi build command to build and optimize your app for production use.
  • yarn lint: (Available when you select eslint feature, via @poi/plugin-eslint) Calls poi lint to run ESLint against app files, optionally allows you to run ESLint on file save.

In the future beta releases, we plan to add @poi/plugin-jest etc to inject poi test command for unit testing.

For Poi 10 users

A list of major differences between v10 and v11:

  • Now you run poi dev instead of poi to start development server
  • A lot of internal API changes for simplification
  • Generator support, you can now use Poi to scaffold out a new project or add files to existing project.
  • ...etc

For more information please:

Top comments (0)