Larsi
Larsi

Reputation: 4774

Vue 2.5 template with Webpack and Typescript

The documentation says that a vue-cli template for typescript is comming soon, but currently none is availible. The official vue guide only shows a recommended tsconfig.json file.

I assume there's lots of additional work getting the all the magic inside webpack to play. And using an old starterkit based on an outdated version of webpack will, based on previous projects, give me hours of future headache.

So, If somebody already have gone through the trouble of creating a vue/vuex/webpack/typescript I'd be really happy if you could share it.

Thanks

Upvotes: 1

Views: 2721

Answers (3)

Ilyas karim
Ilyas karim

Reputation: 4812

You can try this boilerplate provided by Microsoft called: TypeScript Vue Starter. Simply you can run:

npm install --save-dev typescript webpack ts-loader css-loader vue vue-loader vue-template-compiler

And add web pack configuration from documentation to get started.

You can find it Here

Upvotes: 0

vahdet
vahdet

Reputation: 6749

Well, I feel the release of the official vue-cli template is close. But since I have no clue how close it is, maybe yu can start with ducksoupdev's template here (and good news, it says it is already for [email protected]):

https://github.com/ducksoupdev/vue-webpack-typescript

Apparently, it does not contain vuex initializations, but can be a good starting point. All in all, the actual official templates do not include vuex neither.

Upvotes: 1

Omri Lugasi
Omri Lugasi

Reputation: 327

I created a Vue project with TypeScript, webpack, vuex and vue-component-class.

It's for my friend, so you can use it too.

  1. Download the zip file from my google drive zip.

  2. npm install

  3. Open your browser.

  4. http://localhost:3443

Upvotes: 1

Related Questions