1
0
mirror of https://github.com/S2-/ejs-render-remote synced 2025-08-02 20:50:04 +02:00

5 Commits

Author SHA1 Message Date
s2
2701eb3060 1.0.13 2020-02-12 19:37:44 +01:00
s2
ad9d3b9be9 just throw when called sync 2020-02-12 19:37:36 +01:00
s2
21d9319f97 1.0.12 2020-02-08 22:38:28 +01:00
s2
371d16bc2e s/then/done/ 2020-02-08 22:37:54 +01:00
s2
d53c239f90 no-console 2020-02-08 18:24:09 +01:00
3 changed files with 6 additions and 9 deletions

View File

@@ -28,6 +28,7 @@
"dot-notation": 0,
"no-multi-str": 2,
"key-spacing": [2, {"afterColon": true}],
"func-call-spacing": [2, "never"]
"func-call-spacing": [2, "never"],
"no-console": "warn"
}
}

View File

@@ -25,11 +25,7 @@
//if the template is already cached, return it and we are done
if (templateFn) {
try {
return templateFn(data);
} catch(ex) {
$.readyException(ex);
}
} else { //if the template is not cached, we need to get it and render it later once we have it. remember: this happens only if the template is not already cached
@@ -41,7 +37,7 @@
}
var r = uuidv4();
getTemplateFn.then(function(template) {
getTemplateFn.done(function(template) {
var templateOptions = overwriteWithCacheOptions(options, templateUrl);
try {
@@ -72,7 +68,7 @@
d.resolve(templateUrl);
} else {
$.get(templateUrl)
.then(function(template) {
.done(function(template) {
try {
var templateOptions = overwriteWithCacheOptions(options, templateUrl);
var templateFn = ejs.compile(template, templateOptions);

View File

@@ -1,6 +1,6 @@
{
"name": "ejs-render-remote",
"version": "1.0.11",
"version": "1.0.13",
"description": "",
"main": "index.js",
"homepage": "https://github.com/S2-/ejs-render-remote",