Skip to content

Commit d29f78f

Browse files
authored
Merge pull request #18 from cyclejs-community/v2
Upgrade starter to v2
2 parents a2e5b27 + 7f2d57a commit d29f78f

31 files changed

+5819
-114
lines changed

.editorconfig

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
root = true
2+
3+
[*]
4+
end_of_line = lf
5+
insert_final_newline = true
6+
indent_style = space
7+
indent_size = 2

.gitignore

-3
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,3 @@ jspm_packages
3838

3939
# Generated files
4040
dist
41-
42-
# Typings
43-
typings/

.vscode/launch.json

+5-15
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,14 @@
11
{
2+
// Use IntelliSense to learn about possible attributes.
3+
// Hover to view descriptions of existing attributes.
4+
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
25
"version": "0.2.0",
36
"configurations": [
47
{
5-
"name": "Launch Chrome against localhost, with sourcemaps",
68
"type": "chrome",
79
"request": "launch",
8-
"url": "http://localhost:3000",
9-
"sourceMaps": true,
10-
"webRoot": "${workspaceRoot}",
11-
12-
//This line is important, since it instructs chrome to run in a separate, sandbox instance.
13-
//This way, other running chrome instances won't prevent remote debugging from running.
14-
"userDataDir": "C:\\temp\\chrome-dev-instance"
15-
},
16-
{
17-
"name": "Attach to Chrome, with sourcemaps",
18-
"type": "chrome",
19-
"request": "attach",
20-
"port": 9222,
21-
"sourceMaps": true,
10+
"name": "Launch Chrome against localhost",
11+
"url": "http://localhost:3030",
2212
"webRoot": "${workspaceRoot}"
2313
}
2414
]

LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2016 Cycle.js Community
3+
Copyright (c) 2017 Sudarsan Balaji and Cycle.js Community
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

+32-16
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,38 @@
11
# typescript-starter-cycle
2-
A simple project for getting started with TypeScript in cycle.js, using Webpack.
2+
An opinionated starter for Cycle.js projects powered by TypeScript.
33

4-
## Patterns
5-
* Simple Starter - this branch
6-
* [Model-View-Intent (MVI) Starter](https://github.com/cyclejs-community/typescript-starter-cycle/tree/add-model-view-intent-pattern)
7-
* [MVI with Reducers Starter](https://github.com/cyclejs-community/typescript-starter-cycle/tree/add-reducer-pattern)
8-
* [MVI with Property Streams Starter](https://github.com/cyclejs-community/typescript-starter-cycle/tree/add-property-stream-pattern)
4+
## Opinions
5+
* TypeScript rocks. We use TypeScript as much as possible.
6+
* Visual Studio Code rocks. We use Visual Studio Code as the recommended editor.
7+
* Webpack rocks. We use webpack only.
98

10-
<br>
11-
<br>
12-
<br>
13-
<br>
14-
<hr>
9+
## Features
10+
* TypeScript
11+
* Webpack
12+
* TypeStyle for styles
13+
* Simple routing with layouts
14+
* Hot Module Reloading
15+
* Async imports and dynamic routing
16+
* Visual Studio Code integrations
1517

16-
##### Visual Studio Code Specifics
17-
This repository has workspace settings and launch configuration for [Visual Studio Code](https://code.visualstudio.com/) as candy. The launch configuration will only work when the [Debugger for Chrome extension](https://code.visualstudio.com/blogs/2016/02/23/introducing-chrome-debugger-for-vs-code) is installed. The [npm Script Runner extension](https://marketplace.visualstudio.com/items?itemName=eg2.vscode-npm-script) for Visual Studio Code is also recommended.
18+
### Planned
19+
* Unit testing with Mocha and Chai
20+
* UI Integration tests with Cypress
21+
* Explanation of folder structure
22+
* Wiki section on recommended/best practices
23+
* Better README (duh!)
1824

19-
For a quickstart guide/tutorial, see [here](https://journal.artfuldev.com/cycle-js-quick-start-with-typescript-and-webpack-in-visual-studio-code-e562a009e9d6#.qpn2b7vkl)
25+
## Notes
2026

21-
##### Notes
22-
> If hosting on github-pages, you need to remove `dist` entry in the `.gitignore` file.
27+
### Visual Studio Code Specifics
28+
This repository is optimized for [Visual Studio Code](https://code.visualstudio.com/).
29+
We have launch configurations, an editor config file, and workspace settings.
30+
31+
To make full use of these, you need the following extensions:
32+
* [Debugger for Chrome](https://marketplace.visualstudio.com/items?itemName=msjsdiag.debugger-for-chrome)
33+
* [EditorConfig for VS Code](https://marketplace.visualstudio.com/items?itemName=EditorConfig.EditorConfig)
34+
35+
### Troubleshooting / Tips
36+
* If using on Windows machines, make sure you have the [build tools](https://github.com/felixrieseberg/windows-build-tools) ready before doing an `npm install`.
37+
* If hosting on a subdirectory, you need to change the `PROJECT_PUBLIC_PATH` in `webpack.config.js` only for production. You can do this by changing line #32 of the file to `var PROJECT_PUBLIC_PATH = __PROD__ ? '<your-public-path-here>' : '/';`
38+
* If you need help with something, or have feedback, suggestions, feel free to open an issue on this repository.

0 commit comments

Comments
 (0)