- Environment to prepare
- Install the dart SDK, official webdev.dartlang.org/tools/sdk#i installation configuration address…
- Configure the environment variable Path={SDK Path}/bin.
- Create a web project, refer to the official webdev.dartlang.org/guides/get-…
- Create a project
- In idea or Webstorm, select Create New Project and go to File > New > Project…
- Dart project is selected in the left selection bar, idea is not available by default, you need to install your own plug-in.
- Select the installation directory for the Dart SDK and set the name of the project.
- Select Generate Sample Content mode Select a template to create the Web.
- This example selectsBare-bones Web AppTemplate. Click Create to Create the project.
- Start the service
- Calling pub get downloads the dependencies in the pubspce. Yaml file.
- Call Webdev Serve to start the service. Webdev needs to be installed separately. The direct method can be selected from the pub command to set the global mode: Pub Global activate webdev, the default installation path is C:\Users\{username}\AppData\Roaming\ pub \Cache\global_packages\webdev\bin, add this path to the environment variable.
- Access localhost: 8080