grunt-include-source
Advanced tools
Comparing version
@@ -7,2 +7,6 @@ # Changelog | ||
### 2015-02-21 ver. 0.5.1 | ||
* Add TypeScript support. | ||
### 2015-02-21 ver. 0.5.0 | ||
@@ -9,0 +13,0 @@ |
@@ -47,3 +47,4 @@ /* | ||
'<%= vars.jsPath %>/main.js', | ||
] | ||
], | ||
tsPath: 'ts' | ||
}, | ||
@@ -92,2 +93,7 @@ | ||
} | ||
}, | ||
tsTest: { | ||
files: { | ||
'tmp/references.ts': '<%= vars.testFilesPath %>/references.ts' | ||
} | ||
} | ||
@@ -94,0 +100,0 @@ }, |
{ | ||
"name": "grunt-include-source", | ||
"description": "Include your sources into your HTML files automatically.", | ||
"version": "0.5.0", | ||
"version": "0.5.1", | ||
"homepage": "https://github.com/jwvdiermen/grunt-include-source", | ||
@@ -6,0 +6,0 @@ "author": { |
@@ -57,3 +57,3 @@ # grunt-include-source | ||
The templates for sources included in `html`, `haml`, `jade`, `scss`, `less` files. Definition of single template overrides its default equivalent only. | ||
The templates for sources included in `html`, `haml`, `jade`, `scss`, `less`, `ts` files. Definition of single template overrides its default equivalent only. | ||
@@ -86,2 +86,5 @@ Example: | ||
css: '@import "{filePath}";', | ||
}, | ||
ts: { | ||
ts: '/// <reference path="{filePath}" />' | ||
} | ||
@@ -119,3 +122,3 @@ } | ||
### Include syntax | ||
Currently supported: `html`, `haml`, `jade`, `scss` and `less` | ||
Currently supported: `html`, `haml`, `jade`, `scss`, `less` and `ts` (TypeScript). | ||
@@ -128,2 +131,5 @@ #### HTML and CSHTML syntax | ||
#### TS syntax | ||
`/// <!-- include: options_go_here_as_json -->` | ||
#### include.type | ||
@@ -130,0 +136,0 @@ The type of files that are being included. |
@@ -61,3 +61,4 @@ /* | ||
'jade': parseSource('JADE', /\/\/-?\s+include:\s+(.*)/gi), | ||
'scss': parseSource('SASS', /\/\/\s+include:\s+(.*)/gi) | ||
'scss': parseSource('SASS', /\/\/\s+include:\s+(.*)/gi), | ||
'ts': parseSource('TS', /\/\/\/\s<!---?\s*include:\s+(.*)\s*-?--\s*>/gi) | ||
}; | ||
@@ -69,3 +70,4 @@ | ||
'jade': findEndMarker('JADE', /\/\/-?\s+\/include/i), | ||
'scss': findEndMarker('SASS', /\/\/\s+\/include/i) | ||
'scss': findEndMarker('SASS', /\/\/\s+\/include/i), | ||
'ts': findEndMarker('TS', /\/\/\/\s<!---?\s*\/include\s+-?--\>/i) | ||
}; | ||
@@ -93,2 +95,6 @@ | ||
'css': '@import "{filePath}";' | ||
}, | ||
'ts': | ||
{ | ||
'ts': '/// <reference path="{filePath}" />' | ||
} | ||
@@ -95,0 +101,0 @@ }; |
62314
2.71%62
14.81%494
7.16%276
2.22%7
16.67%