mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
copied code from #12429
This commit is contained in:
@@ -7,8 +7,7 @@ Package.describe({
|
||||
});
|
||||
|
||||
Npm.depends({
|
||||
parse5: '3.0.2',
|
||||
'stream-to-string': '1.1.0'
|
||||
parse5: '6.0.1'
|
||||
});
|
||||
|
||||
Package.onTest(function (api) {
|
||||
|
||||
@@ -1,4 +1,11 @@
|
||||
import streamToString from "stream-to-string";
|
||||
function streamToString (stream) {
|
||||
const chunks = [];
|
||||
return new Promise((resolve, reject) => {
|
||||
stream.on('data', (chunk) => chunks.push(Buffer.from(chunk)));
|
||||
stream.on('error', (err) => reject(err));
|
||||
stream.on('end', () => resolve(Buffer.concat(chunks).toString('utf8')));
|
||||
})
|
||||
}
|
||||
|
||||
export async function generateHTMLForArch(arch, includeHead) {
|
||||
// Use a dummy manifest. None of these paths will be read from the filesystem, but css / js should be handled differently
|
||||
|
||||
Reference in New Issue
Block a user