1 | # MagiX
|
2 |
|
3 | Beyond magical.
|
4 | [magixjs](https://magixjs.com)
|
5 |
|
6 | MagiXJS allow you to create the most advance webapps ever built.
|
7 | Combined with Coffeescript, MagiX get ride of HTML/CSS and Javascript allowing you to create webapps only using one language and one framework. It is easy to learn and will push your next project to new heights.
|
8 |
|
9 | # Install
|
10 |
|
11 | > npm install -g magixjs
|
12 |
|
13 | # Commands
|
14 |
|
15 | ## magix about
|
16 |
|
17 | * About Magix.
|
18 |
|
19 | ## magix create [type]
|
20 |
|
21 | * Allow you to create a project.
|
22 | * Type: [app, playground]
|
23 |
|
24 | ex: magix create app
|
25 |
|
26 | ## magix launch [dir] [port]
|
27 |
|
28 | * Launch a local server to help you code an orb project.
|
29 |
|
30 | ## magix build [project dir] [env]
|
31 |
|
32 | * Build your project.
|
33 | * magix build production
|
34 | ** Optimize your project for a production environement (merge files, minify..).
|
35 |
|
36 | ## magix clean [project dir]
|
37 |
|
38 | * Clear the build of a project.
|
39 |
|
40 | ## magix watch [project dir]
|
41 |
|
42 | * Observe change on a project and compile on the fly.
|
43 | * Note: when doing a 'magix launch' you do not need to do an 'magix watch'
|
44 |
|
45 | ex: magix watch
|
46 |
|
47 |
|
48 | # Example
|
49 |
|
50 | ## Create your first project:
|
51 |
|
52 | > magix create demo
|
53 |
|
54 | > > Magix: Project created successfully.
|
55 |
|
56 | > cd orb-demo
|
57 |
|
58 | > magix launch
|
59 |
|
60 | ## Create production version of your project
|
61 | ## (Will create copy of your project that will be minified and optimized)
|
62 |
|
63 | > magix clean
|
64 |
|
65 | > magix build production
|
66 |
|
67 | # About magix projects
|
68 |
|
69 | * You code using COFFEESCRIPT.
|
70 | * No HTML, no CSS, no javascript required.
|
71 | * No need for anything else out of the box.
|
72 | * To create a class, create a new file and write:
|
73 |
|
74 | > Extends View
|
75 |
|
76 | > this.background = red
|
77 |
|
78 | > this.didAppear = ->
|
79 |
|
80 | > say 'hi'
|
81 |
|
82 | ## .. Instead of the traditional 'class' keyword
|
83 |
|
84 | * One class per file
|
85 |
|
86 | * Classes are auto imported by default.
|
87 | To import classes manually, add a '!' at the very beggining of you file.
|
88 | Then:
|
89 | > Import 'MyFirstView', ->
|
90 |
|
91 | > log 'imported'
|
92 |
|
93 | ## In case you are wondering, 'log' is the print method, short and cool ;)
|
94 |
|
95 | > log 'something :P'
|
96 |
|
97 | # Documentation / help
|
98 |
|
99 | To find help visit:
|
100 |
|
101 | [Magix Documentation](https://magixjs.com/learn)
|
102 |
|
103 | [Twitter](https://twitter.com/magixjs)
|
104 |
|
105 | # About
|
106 | Created by Etienne Pinchon (@etiennepinchon)
|
107 |
|
108 | [Twitter](https://twitter.com/etiennepinchon)
|
109 |
|
110 | ©2016 |
\ | No newline at end of file |