Skip to content

Commit

Permalink
Merge pull request #448 from meteor/revert-433-feature/update-caching…
Browse files Browse the repository at this point in the history
…-html-compiler

Revert "Update caching-html-compiler"
  • Loading branch information
Grubba27 authored Dec 29, 2023
2 parents 3fdd170 + 177ee26 commit 14b626c
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 12 deletions.
4 changes: 0 additions & 4 deletions .jshintrc

This file was deleted.

9 changes: 4 additions & 5 deletions packages/caching-html-compiler/caching-html-compiler.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import isEmpty from 'lodash.isempty';
import { CachingCompiler } from 'meteor/caching-compiler';

const path = Plugin.path;

Expand Down Expand Up @@ -117,14 +116,14 @@ CachingHtmlCompiler = class CachingHtmlCompiler extends CachingCompiler {
// Add JavaScript code to set attributes on body
allJavaScript +=
`Meteor.startup(function() {
const attrs = ${JSON.stringify(compileResult.bodyAttrs)};
for (let prop in attrs) {
var attrs = ${JSON.stringify(compileResult.bodyAttrs)};
for (var prop in attrs) {
document.body.setAttribute(prop, attrs[prop]);
}
});
`;
}


if (allJavaScript) {
const filePath = inputFile.getPathInPackage();
Expand All @@ -145,4 +144,4 @@ CachingHtmlCompiler = class CachingHtmlCompiler extends CachingCompiler {
});
}
}
};
}
6 changes: 3 additions & 3 deletions packages/caching-html-compiler/package.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package.describe({
name: 'caching-html-compiler',
summary: "Pluggable class for compiling HTML into templates",
version: '1.2.2',
version: '1.2.1',
git: 'https://github.com/meteor/blaze.git'
});

Expand All @@ -12,13 +12,13 @@ Npm.depends({
Package.onUse(function(api) {
api.use([
'caching-compiler@1.2.2',
'ecmascript@0.16.7'
'ecmascript@0.15.1'
]);

api.export('CachingHtmlCompiler', 'server');

api.use([
'templating-tools@1.2.2'
'templating-tools@1.2.1'
]);

api.addFiles([
Expand Down

0 comments on commit 14b626c

Please sign in to comment.