You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+28-3Lines changed: 28 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,4 @@
1
-
# Grunt/Gulp for Mendix theming
1
+
# Gulp for Mendix theming
2
2
3
3
Make it easier to develop Mendix themes, without the use of [Scout](https://docs.mendix.com/howto/ux/create-a-custom-theme-with-the-mendix-ui-framework) or [Koala](https://docs.mendix.com/howto/ux/setup-mendix-ui-framework-with-koala)
4
4
@@ -8,7 +8,7 @@ The following things need to be installed:
8
8
*[Node.js](https://nodejs.org/en/)**Please ensure you install the LTS version, 8.x.x. This is important!! It will fail on older versions like Node 6.x.x**
9
9
10
10
If you want to use Gulp (**recommended**):
11
-
*[Gulp client](https://github.com/gulpjs/gulp/blob/master/docs/getting-started.md) (you can install this after installing Node using ```npm install gulp-cli -g```)
11
+
*[Gulp client](https://github.com/gulpjs/gulp/blob/master/docs/getting-started.md) (you can install this after installing Node using ```npm install gulp-cli -g```). **Note: Per version 1.6.0 this is unnecessary, because you can run it using npm**
12
12
13
13
If you want to use Grunt:
14
14
*[Grunt client](http://gruntjs.com/getting-started) (you can install this after installing Node using ```npm install grunt-cli -g```)
@@ -18,7 +18,7 @@ Note:
18
18
19
19
## Installation
20
20
21
-
1.) Download the latest release (ZIP-file) [here](https://github.com/JelteMX/ux-grunt-theming/releases). **Do NOT download the source files, but choose Gulp.zip or Grunt.zip**
21
+
1.) Download the latest release (ZIP-file) [here](https://github.com/JelteMX/ux-grunt-theming/releases). **Do NOT download the source files, but choose Gulp.zip**
22
22
23
23
2.) Unzip in your project root folder
24
24
@@ -32,6 +32,23 @@ _If you do this on Windows and you encounter errors with installing the dependen
32
32
33
33
## Usage
34
34
35
+
### 1.6.0 and newer
36
+
Per version 1.6.0 you can use the following tass using **npm** instead of **gulp**:
37
+
38
+
***default**
39
+
40
+
```bash
41
+
npm run start
42
+
```
43
+
44
+
***dev**
45
+
46
+
```bash
47
+
npm run dev
48
+
```
49
+
50
+
### 1.5.1 and older
51
+
35
52
Based on your choice between Gulp or Grunt, you have the following options:
36
53
37
54
***default**, run from commandline:
@@ -58,6 +75,8 @@ or
58
75
grunt dev
59
76
```
60
77
78
+
### Tasks:
79
+
61
80
The **default** task will check your theme folder (check Gruntfile.js/Gulpfile.js for the location) and will:
62
81
* copy changed .css files to your deployment folder
63
82
* when there are changes detected in any ```.scss``` file, run sass and place them in the source folder (on which these files will be copied to deployment as well)
@@ -109,6 +128,12 @@ This is a common problem when you are using this in new Mendix Projects where it
109
128
110
129
This should fix your problem with missing stylesheets after a reload
111
130
131
+
#### **"I get the following error:"**
132
+
133
+
> ``gulpInst.start.apply(gulpInst, toRun); TypeError: Cannot read property 'apply' of undefined``
134
+
135
+
Your Gulp is outdated. Please run ``npm install gulp-cli -g`` again. Or use **npm**, see usage for 1.6.0 and newer.
136
+
112
137
## Done theming?
113
138
114
139
If you do not want the theming files to be part of the project (you can safely commit them, as long as you will add ``node_modules`` to **SVN Ignore**), you can clean your project folder by deleting:
0 commit comments