Compare commits
No commits in common. "02220d88ae677d6e307e2f793fe9873674fb4390" and "48f2503807a6f7ad7eb45388524bccb505889fa3" have entirely different histories.
02220d88ae
...
48f2503807
|
@ -1415,11 +1415,6 @@
|
|||
"rollup": "^2.34.0"
|
||||
}
|
||||
},
|
||||
"snowpack-plugin-selective-import-to-require": {
|
||||
"version": "0.1.1",
|
||||
"resolved": "https://registry.npmjs.org/snowpack-plugin-selective-import-to-require/-/snowpack-plugin-selective-import-to-require-0.1.1.tgz",
|
||||
"integrity": "sha512-E6HctZX9zAgM2Yjr5R4HKMoSDdxMpglRs1ubvFZKXc9EgnbiqcW7Rx11k6U5aG6V4NaQeiQ4E/2x4i+iGEYRSg=="
|
||||
},
|
||||
"source-map": {
|
||||
"version": "0.7.3",
|
||||
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.3.tgz",
|
||||
|
|
|
@ -23,7 +23,6 @@
|
|||
"wait-on": "^5.2.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"snowpack-plugin-selective-import-to-require": "^0.1.1",
|
||||
"svelte": "^3.32.3"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,9 +13,6 @@ module.exports = {
|
|||
/* ... */
|
||||
'@snowpack/plugin-svelte',
|
||||
'@snowpack/plugin-typescript',
|
||||
['snowpack-plugin-selective-import-to-require', {
|
||||
"modules": builtinModules,
|
||||
}],
|
||||
],
|
||||
routes: [
|
||||
/* Enable an SPA Fallback in development: */
|
||||
|
@ -27,6 +24,7 @@ module.exports = {
|
|||
},
|
||||
packageOptions: {
|
||||
/* ... */
|
||||
external: [...builtinModules.filter((external) => external !== 'process'), 'electron'],
|
||||
},
|
||||
devOptions: {
|
||||
/* ... */
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
import { TransformOptions, Transform, Readable, Writable } from 'stream'
|
||||
let { TransformOptions, Transform, Readable, Writable } = require('stream')
|
||||
//import { TransformOptions, Transform, Readable, Writable } from 'stream'
|
||||
|
||||
class JSONReader extends Transform {
|
||||
constructor(options: TransformOptions) {
|
||||
constructor(options: typeof TransformOptions) {
|
||||
super(options)
|
||||
}
|
||||
_transform(data: string, encoding: string, cb: (chunk:any, err?:any) => void) {
|
||||
|
@ -15,15 +16,15 @@ class JSONReader extends Transform {
|
|||
|
||||
export class ServiceBroker {
|
||||
|
||||
protected jsonWriter: Transform = new Transform({
|
||||
protected jsonWriter: typeof Transform = new Transform({
|
||||
objectMode: true,
|
||||
})
|
||||
protected errorReader: Transform = new Transform({ })
|
||||
protected errorReader: typeof Transform = new Transform({ })
|
||||
protected jsonReader: JSONReader = new JSONReader({
|
||||
objectMode: true,
|
||||
})
|
||||
|
||||
constructor(input: Readable, output: Writable, error: Readable) {
|
||||
constructor(input: typeof Readable, output: typeof Writable, error: typeof Readable) {
|
||||
// Set up our reader callback.
|
||||
this.jsonReader.on("data", (json: any) => {
|
||||
// TODO: Something with our object
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
import { spawn } from 'child_process'
|
||||
import os from 'os'
|
||||
let { spawn } = require('child_process')
|
||||
let os = require('os')
|
||||
/*import { spawn } from 'child_process'
|
||||
import os from 'os'*/
|
||||
//import path from 'path'
|
||||
let path = require('path')
|
||||
import { ServiceBroker } from './ServiceBroker'
|
||||
|
||||
export async function createServiceBroker(exe = "service" + (os.platform()==='win32'?'.exe':'')): Promise<ServiceBroker> {
|
||||
|
|
Loading…
Reference in New Issue