Merge branch 'feature/debug' into 'master'
Feature/debug See merge request !8
This commit is contained in:
commit
6d7a93ff18
@ -15,29 +15,33 @@
|
|||||||
*/
|
*/
|
||||||
package pub.doric.demo;
|
package pub.doric.demo;
|
||||||
|
|
||||||
import androidx.appcompat.app.AppCompatActivity;
|
|
||||||
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
|
import android.view.KeyEvent;
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
import android.widget.FrameLayout;
|
import android.widget.FrameLayout;
|
||||||
|
|
||||||
|
import androidx.appcompat.app.AppCompatActivity;
|
||||||
|
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import pub.doric.dev.DevPanel;
|
||||||
import pub.doric.Doric;
|
import pub.doric.Doric;
|
||||||
import pub.doric.DoricContext;
|
import pub.doric.DoricContext;
|
||||||
import pub.doric.dev.LocalServer;
|
import pub.doric.dev.LocalServer;
|
||||||
import pub.doric.utils.DoricUtils;
|
import pub.doric.utils.DoricUtils;
|
||||||
|
|
||||||
import java.io.IOException;
|
|
||||||
|
|
||||||
|
|
||||||
public class MainActivity extends AppCompatActivity {
|
public class MainActivity extends AppCompatActivity {
|
||||||
|
|
||||||
|
private DevPanel mDevPanel = new DevPanel();
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
setContentView(R.layout.activity_main);
|
setContentView(R.layout.activity_main);
|
||||||
DoricContext doricContext = DoricContext.create(this, DoricUtils.readAssetFile("demo/Snake.js"), "test");
|
DoricContext doricContext = DoricContext.create(this, DoricUtils.readAssetFile("demo/Snake.js"), "test");
|
||||||
doricContext.init(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT);
|
doricContext.init(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT);
|
||||||
doricContext.callEntity("log");
|
// doricContext.callEntity("log");
|
||||||
doricContext.getRootNode().setRootView((FrameLayout) findViewById(R.id.root));
|
doricContext.getRootNode().setRootView((FrameLayout) findViewById(R.id.root));
|
||||||
Doric.connectDevKit("ws://192.168.11.38:7777");
|
Doric.connectDevKit("ws://192.168.11.38:7777");
|
||||||
LocalServer localServer = new LocalServer(getApplicationContext(), 8910);
|
LocalServer localServer = new LocalServer(getApplicationContext(), 8910);
|
||||||
@ -47,4 +51,12 @@ public class MainActivity extends AppCompatActivity {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean onKeyDown(int keyCode, KeyEvent event) {
|
||||||
|
if (KeyEvent.KEYCODE_MENU == event.getKeyCode()) {
|
||||||
|
mDevPanel.show(getSupportFragmentManager(), "DevPanel");
|
||||||
|
}
|
||||||
|
return super.onKeyDown(keyCode, event);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
tools:context="com.github.penfeizhou.doricdemo.pub.doric.demo.MainActivity">
|
tools:context=".MainActivity">
|
||||||
|
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
android:id="@+id/root"
|
android:id="@+id/root"
|
||||||
|
@ -49,9 +49,11 @@ dependencies {
|
|||||||
implementation 'androidx.appcompat:appcompat:1.1.0'
|
implementation 'androidx.appcompat:appcompat:1.1.0'
|
||||||
api 'com.github.pengfeizhou:jsc4a:0.1.0'
|
api 'com.github.pengfeizhou:jsc4a:0.1.0'
|
||||||
implementation 'com.squareup.okhttp3:okhttp:4.2.1'
|
implementation 'com.squareup.okhttp3:okhttp:4.2.1'
|
||||||
implementation 'com.github.penfeizhou.android.animation:glide-plugin:1.0.1'
|
implementation 'com.github.penfeizhou.android.animation:glide-plugin:1.1.0'
|
||||||
api 'org.nanohttpd:nanohttpd:2.3.1'
|
api 'org.nanohttpd:nanohttpd:2.3.1'
|
||||||
implementation 'com.google.code.gson:gson:2.8.6'
|
implementation 'com.google.code.gson:gson:2.8.6'
|
||||||
|
api "com.google.android.material:material:1.0.0"
|
||||||
|
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
|
||||||
|
|
||||||
testImplementation 'junit:junit:4.12'
|
testImplementation 'junit:junit:4.12'
|
||||||
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
|
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
|
||||||
|
@ -62,7 +62,6 @@ public class DoricContext {
|
|||||||
public static DoricContext create(Context context, String script, String source) {
|
public static DoricContext create(Context context, String script, String source) {
|
||||||
DoricContext doricContext = DoricContextManager.getInstance().createContext(context, script, source);
|
DoricContext doricContext = DoricContextManager.getInstance().createContext(context, script, source);
|
||||||
doricContext.script = script;
|
doricContext.script = script;
|
||||||
doricContext.callEntity(DoricConstant.DORIC_ENTITY_CREATE);
|
|
||||||
return doricContext;
|
return doricContext;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -71,6 +70,8 @@ public class DoricContext {
|
|||||||
.put("width", width)
|
.put("width", width)
|
||||||
.put("height", height).toJSONObject();
|
.put("height", height).toJSONObject();
|
||||||
callEntity(DoricConstant.DORIC_ENTITY_INIT, this.initParams);
|
callEntity(DoricConstant.DORIC_ENTITY_INIT, this.initParams);
|
||||||
|
|
||||||
|
callEntity(DoricConstant.DORIC_ENTITY_CREATE);
|
||||||
}
|
}
|
||||||
|
|
||||||
public AsyncResult<JSDecoder> callEntity(String methodName, Object... args) {
|
public AsyncResult<JSDecoder> callEntity(String methodName, Object... args) {
|
||||||
|
30
Android/doric/src/main/java/pub/doric/dev/DevPanel.java
Normal file
30
Android/doric/src/main/java/pub/doric/dev/DevPanel.java
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
package pub.doric.dev;
|
||||||
|
|
||||||
|
import android.os.Bundle;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
|
import androidx.annotation.NonNull;
|
||||||
|
import androidx.annotation.Nullable;
|
||||||
|
|
||||||
|
import com.google.android.material.bottomsheet.BottomSheetDialogFragment;
|
||||||
|
|
||||||
|
import pub.doric.R;
|
||||||
|
|
||||||
|
public class DevPanel extends BottomSheetDialogFragment {
|
||||||
|
|
||||||
|
public DevPanel() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Nullable
|
||||||
|
@Override
|
||||||
|
public View onCreateView(
|
||||||
|
@NonNull LayoutInflater inflater,
|
||||||
|
@Nullable ViewGroup container,
|
||||||
|
@Nullable Bundle savedInstanceState
|
||||||
|
) {
|
||||||
|
return inflater.inflate(R.layout.layout_dev, container, false);
|
||||||
|
}
|
||||||
|
}
|
@ -4,13 +4,18 @@ import com.github.pengfeizhou.jscore.JSDecoder;
|
|||||||
import com.github.pengfeizhou.jscore.JavaFunction;
|
import com.github.pengfeizhou.jscore.JavaFunction;
|
||||||
import com.github.pengfeizhou.jscore.JavaValue;
|
import com.github.pengfeizhou.jscore.JavaValue;
|
||||||
import com.google.gson.Gson;
|
import com.google.gson.Gson;
|
||||||
|
import com.google.gson.JsonArray;
|
||||||
import com.google.gson.JsonElement;
|
import com.google.gson.JsonElement;
|
||||||
import com.google.gson.JsonObject;
|
import com.google.gson.JsonObject;
|
||||||
|
import com.google.gson.JsonPrimitive;
|
||||||
|
|
||||||
import org.jetbrains.annotations.NotNull;
|
import org.jetbrains.annotations.NotNull;
|
||||||
|
import org.json.JSONObject;
|
||||||
|
|
||||||
import java.io.EOFException;
|
import java.io.EOFException;
|
||||||
import java.net.ConnectException;
|
import java.net.ConnectException;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.Map;
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
import java.util.concurrent.locks.LockSupport;
|
import java.util.concurrent.locks.LockSupport;
|
||||||
|
|
||||||
@ -25,13 +30,17 @@ public class RemoteJSExecutor {
|
|||||||
private final WebSocket webSocket;
|
private final WebSocket webSocket;
|
||||||
private final Gson gson = new Gson();
|
private final Gson gson = new Gson();
|
||||||
|
|
||||||
|
private final Map<String, JavaFunction> globalFunctions = new HashMap<>();
|
||||||
|
|
||||||
|
private JSDecoder temp;
|
||||||
|
|
||||||
public RemoteJSExecutor() {
|
public RemoteJSExecutor() {
|
||||||
OkHttpClient okHttpClient = new OkHttpClient
|
OkHttpClient okHttpClient = new OkHttpClient
|
||||||
.Builder()
|
.Builder()
|
||||||
.readTimeout(10, TimeUnit.SECONDS)
|
.readTimeout(10, TimeUnit.SECONDS)
|
||||||
.writeTimeout(10, TimeUnit.SECONDS)
|
.writeTimeout(10, TimeUnit.SECONDS)
|
||||||
.build();
|
.build();
|
||||||
Request request = new Request.Builder().url("ws://192.168.24.166:2080").build();
|
final Request request = new Request.Builder().url("ws://192.168.24.221:2080").build();
|
||||||
|
|
||||||
final Thread current = Thread.currentThread();
|
final Thread current = Thread.currentThread();
|
||||||
webSocket = okHttpClient.newWebSocket(request, new WebSocketListener() {
|
webSocket = okHttpClient.newWebSocket(request, new WebSocketListener() {
|
||||||
@ -55,43 +64,109 @@ public class RemoteJSExecutor {
|
|||||||
@Override
|
@Override
|
||||||
public void onMessage(@NotNull WebSocket webSocket, @NotNull String text) {
|
public void onMessage(@NotNull WebSocket webSocket, @NotNull String text) {
|
||||||
JsonElement je = gson.fromJson(text, JsonElement.class);
|
JsonElement je = gson.fromJson(text, JsonElement.class);
|
||||||
System.out.println(je);
|
|
||||||
|
|
||||||
|
if (je instanceof JsonObject) {
|
||||||
|
JsonObject jo = ((JsonObject) je);
|
||||||
|
String cmd = jo.get("cmd").getAsString();
|
||||||
|
switch (cmd) {
|
||||||
|
case "injectGlobalJSFunction": {
|
||||||
|
String name = jo.get("name").getAsString();
|
||||||
|
JsonArray arguments = jo.getAsJsonArray("arguments");
|
||||||
|
JSDecoder[] decoders = new JSDecoder[arguments.size()];
|
||||||
|
for (int i = 0; i < arguments.size(); i++) {
|
||||||
|
if (arguments.get(i).isJsonPrimitive()) {
|
||||||
|
JsonPrimitive jp = ((JsonPrimitive) arguments.get(i));
|
||||||
|
if (jp.isNumber()) {
|
||||||
|
ValueBuilder vb = new ValueBuilder(jp.getAsNumber());
|
||||||
|
JSDecoder decoder = new JSDecoder(vb.build());
|
||||||
|
decoders[i] = decoder;
|
||||||
|
} else if (jp.isBoolean()) {
|
||||||
|
ValueBuilder vb = new ValueBuilder(jp.getAsBoolean());
|
||||||
|
JSDecoder decoder = new JSDecoder(vb.build());
|
||||||
|
decoders[i] = decoder;
|
||||||
|
} else if (jp.isString()) {
|
||||||
|
ValueBuilder vb = new ValueBuilder(jp.getAsString());
|
||||||
|
JSDecoder decoder = new JSDecoder(vb.build());
|
||||||
|
decoders[i] = decoder;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
try {
|
||||||
|
ValueBuilder vb = new ValueBuilder(new JSONObject(gson.toJson(arguments.get(i))));
|
||||||
|
JSDecoder decoder = new JSDecoder(vb.build());
|
||||||
|
decoders[i] = decoder;
|
||||||
|
} catch (Exception ex) {
|
||||||
|
ex.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
globalFunctions.get(name).exec(decoders);
|
||||||
|
}
|
||||||
|
|
||||||
|
break;
|
||||||
|
case "invokeMethod": {
|
||||||
|
try {
|
||||||
|
Object result = jo.get("result");
|
||||||
|
ValueBuilder vb = new ValueBuilder(result);
|
||||||
|
JSDecoder decoder = new JSDecoder(vb.build());
|
||||||
|
temp = decoder;
|
||||||
|
System.out.println(result);
|
||||||
|
} catch (Exception ex) {
|
||||||
|
ex.printStackTrace();
|
||||||
|
} finally {
|
||||||
LockSupport.unpark(current);
|
LockSupport.unpark(current);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
});
|
});
|
||||||
LockSupport.park(current);
|
LockSupport.park(current);
|
||||||
}
|
}
|
||||||
|
|
||||||
public String loadJS(String script, String source) {
|
public String loadJS(String script, String source) {
|
||||||
JsonObject jo = new JsonObject();
|
|
||||||
jo.addProperty("cmd", "loadJS");
|
|
||||||
jo.addProperty("script", script);
|
|
||||||
jo.addProperty("source", source);
|
|
||||||
webSocket.send(gson.toJson(jo));
|
|
||||||
|
|
||||||
LockSupport.park(Thread.currentThread());
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
public JSDecoder evaluateJS(String script, String source, boolean hashKey) {
|
public JSDecoder evaluateJS(String script, String source, boolean hashKey) {
|
||||||
JsonObject jo = new JsonObject();
|
|
||||||
jo.addProperty("cmd", "evaluateJS");
|
|
||||||
jo.addProperty("script", script);
|
|
||||||
jo.addProperty("source", source);
|
|
||||||
jo.addProperty("hashKey", hashKey);
|
|
||||||
webSocket.send(gson.toJson(jo));
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void injectGlobalJSFunction(String name, JavaFunction javaFunction) {
|
public void injectGlobalJSFunction(String name, JavaFunction javaFunction) {
|
||||||
|
globalFunctions.put(name, javaFunction);
|
||||||
|
|
||||||
|
JsonObject jo = new JsonObject();
|
||||||
|
jo.addProperty("cmd", "injectGlobalJSFunction");
|
||||||
|
jo.addProperty("name", name);
|
||||||
|
webSocket.send(gson.toJson(jo));
|
||||||
}
|
}
|
||||||
|
|
||||||
public void injectGlobalJSObject(String name, JavaValue javaValue) {
|
public void injectGlobalJSObject(String name, JavaValue javaValue) {
|
||||||
}
|
}
|
||||||
|
|
||||||
public JSDecoder invokeMethod(String objectName, String functionName, JavaValue[] javaValues, boolean hashKey) {
|
public JSDecoder invokeMethod(String objectName, String functionName, JavaValue[] javaValues, boolean hashKey) {
|
||||||
return null;
|
JsonObject jo = new JsonObject();
|
||||||
|
jo.addProperty("cmd", "invokeMethod");
|
||||||
|
jo.addProperty("objectName", objectName);
|
||||||
|
jo.addProperty("functionName", functionName);
|
||||||
|
|
||||||
|
JsonArray ja = new JsonArray();
|
||||||
|
for (JavaValue javaValue : javaValues) {
|
||||||
|
JsonObject argument = new JsonObject();
|
||||||
|
argument.addProperty("type", javaValue.getType());
|
||||||
|
argument.addProperty("value", javaValue.getValue());
|
||||||
|
ja.add(argument);
|
||||||
|
}
|
||||||
|
jo.add("javaValues", ja);
|
||||||
|
|
||||||
|
jo.addProperty("hashKey", hashKey);
|
||||||
|
webSocket.send(gson.toJson(jo));
|
||||||
|
|
||||||
|
LockSupport.park(Thread.currentThread());
|
||||||
|
return temp;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void destroy() {
|
public void destroy() {
|
||||||
|
@ -0,0 +1,91 @@
|
|||||||
|
package pub.doric.engine.remote;
|
||||||
|
|
||||||
|
import org.json.JSONArray;
|
||||||
|
import org.json.JSONObject;
|
||||||
|
|
||||||
|
import java.io.ByteArrayOutputStream;
|
||||||
|
import java.util.Iterator;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by pengfei.zhou on 2018/4/17.
|
||||||
|
*/
|
||||||
|
public class ValueBuilder {
|
||||||
|
private final Object val;
|
||||||
|
|
||||||
|
private void writeBoolean(ByteArrayOutputStream output, boolean b) {
|
||||||
|
output.write((byte) (b ? 1 : 0));
|
||||||
|
}
|
||||||
|
|
||||||
|
private void writeInt(ByteArrayOutputStream output, int i) {
|
||||||
|
output.write((byte) (i >>> 24));
|
||||||
|
output.write((byte) (i >>> 16));
|
||||||
|
output.write((byte) (i >>> 8));
|
||||||
|
output.write((byte) i);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void writeDouble(ByteArrayOutputStream output, double d) {
|
||||||
|
long l = Double.doubleToRawLongBits(d);
|
||||||
|
output.write((byte) (l >>> 56));
|
||||||
|
output.write((byte) (l >>> 48));
|
||||||
|
output.write((byte) (l >>> 40));
|
||||||
|
output.write((byte) (l >>> 32));
|
||||||
|
output.write((byte) (l >>> 24));
|
||||||
|
output.write((byte) (l >>> 16));
|
||||||
|
output.write((byte) (l >>> 8));
|
||||||
|
output.write((byte) l);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void writeString(ByteArrayOutputStream output, String S) {
|
||||||
|
byte[] buf;
|
||||||
|
try {
|
||||||
|
buf = S.getBytes("UTF-8");
|
||||||
|
} catch (Exception e) {
|
||||||
|
buf = new byte[0];
|
||||||
|
}
|
||||||
|
int i = buf.length;
|
||||||
|
writeInt(output, i);
|
||||||
|
output.write(buf, 0, i);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void write(ByteArrayOutputStream output, Object O) {
|
||||||
|
if (O instanceof Number) {
|
||||||
|
output.write((byte) 'D');
|
||||||
|
writeDouble(output, Double.valueOf(String.valueOf(O)));
|
||||||
|
} else if (O instanceof String) {
|
||||||
|
output.write((byte) 'S');
|
||||||
|
writeString(output, (String) O);
|
||||||
|
} else if (O instanceof Boolean) {
|
||||||
|
output.write((byte) 'B');
|
||||||
|
writeBoolean(output, (Boolean) O);
|
||||||
|
} else if (O instanceof JSONObject) {
|
||||||
|
output.write((byte) 'O');
|
||||||
|
//writeBoolean(output, (Boolean) O);
|
||||||
|
Iterator<String> iterator = ((JSONObject) O).keys();
|
||||||
|
while (iterator.hasNext()) {
|
||||||
|
String key = iterator.next();
|
||||||
|
write(output, key);
|
||||||
|
write(output, ((JSONObject) O).opt(key));
|
||||||
|
}
|
||||||
|
output.write((byte) 'N');
|
||||||
|
} else if (O instanceof JSONArray) {
|
||||||
|
output.write((byte) 'A');
|
||||||
|
writeInt(output, ((JSONArray) O).length());
|
||||||
|
for (int i = 0; i < ((JSONArray) O).length(); i++) {
|
||||||
|
write(output, ((JSONArray) O).opt(i));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
output.write((byte) 'N');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public ValueBuilder(Object o) {
|
||||||
|
this.val = o;
|
||||||
|
}
|
||||||
|
|
||||||
|
public byte[] build() {
|
||||||
|
ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
|
||||||
|
write(outputStream, val);
|
||||||
|
return outputStream.toByteArray();
|
||||||
|
}
|
||||||
|
}
|
34
Android/doric/src/main/res/layout/layout_dev.xml
Normal file
34
Android/doric/src/main/res/layout/layout_dev.xml
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/menu1_text_view"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="60dp"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="Debug via Visual Studio Code"
|
||||||
|
android:textSize="20sp"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="1dp"
|
||||||
|
android:background="#cccccc" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/menu2_text_view"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="60dp"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="Enable Hot Reload"
|
||||||
|
android:textSize="20sp"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/menu1_text_view" />
|
||||||
|
</LinearLayout>
|
24
demo/.vscode/launch.json
vendored
Normal file
24
demo/.vscode/launch.json
vendored
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
{
|
||||||
|
// Use IntelliSense to learn about possible attributes.
|
||||||
|
// Hover to view descriptions of existing attributes.
|
||||||
|
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
|
||||||
|
"version": "0.2.0",
|
||||||
|
"configurations": [
|
||||||
|
{
|
||||||
|
"type": "node",
|
||||||
|
"request": "launch",
|
||||||
|
"name": "Debug TS",
|
||||||
|
"program": "${workspaceFolder}/${relativeFile}",
|
||||||
|
"preLaunchTask": "Doric Build",
|
||||||
|
"sourceMaps": true,
|
||||||
|
"serverReadyAction": {
|
||||||
|
"pattern": "listening on port ([0-9]+)",
|
||||||
|
"uriFormat": "http://localhost:%s",
|
||||||
|
"action": "openExternally"
|
||||||
|
},
|
||||||
|
"outFiles": [
|
||||||
|
"${workspaceFolder}/bundle/**/*.js"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
28
demo/.vscode/tasks.json
vendored
Normal file
28
demo/.vscode/tasks.json
vendored
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
{
|
||||||
|
// See https://go.microsoft.com/fwlink/?LinkId=733558
|
||||||
|
// for the documentation about the tasks.json format
|
||||||
|
"version": "2.0.0",
|
||||||
|
"tasks": [
|
||||||
|
{
|
||||||
|
"label": "Doric Build",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "doric build",
|
||||||
|
"group": "build",
|
||||||
|
"problemMatcher": []
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "Doric Clean",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "doric clean",
|
||||||
|
"group": "build",
|
||||||
|
"problemMatcher": []
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "Doric Dev",
|
||||||
|
"type": "shell",
|
||||||
|
"command": "doric dev",
|
||||||
|
"group": "build",
|
||||||
|
"problemMatcher": []
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
247
demo/package-lock.json
generated
247
demo/package-lock.json
generated
@ -10,9 +10,9 @@
|
|||||||
"integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw=="
|
"integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw=="
|
||||||
},
|
},
|
||||||
"@types/node": {
|
"@types/node": {
|
||||||
"version": "12.11.1",
|
"version": "12.11.5",
|
||||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-12.11.1.tgz",
|
"resolved": "https://registry.npmjs.org/@types/node/-/node-12.11.5.tgz",
|
||||||
"integrity": "sha512-TJtwsqZ39pqcljJpajeoofYRfeZ7/I/OMUQ5pR4q5wOKf2ocrUvBAZUMhWsOvKx3dVc/aaV5GluBivt0sWqA5A=="
|
"integrity": "sha512-LC8ALj/24PhByn39nr5jnTvpE7MujK8y7LQmV74kHYF5iQ0odCPkMH4IZNZw+cobKfSXqaC8GgegcbIsQpffdA=="
|
||||||
},
|
},
|
||||||
"@types/resolve": {
|
"@types/resolve": {
|
||||||
"version": "0.0.8",
|
"version": "0.0.8",
|
||||||
@ -306,12 +306,14 @@
|
|||||||
"doric": {
|
"doric": {
|
||||||
"version": "file:../js-framework",
|
"version": "file:../js-framework",
|
||||||
"requires": {
|
"requires": {
|
||||||
|
"@types/ws": "^6.0.3",
|
||||||
"reflect-metadata": "^0.1.13",
|
"reflect-metadata": "^0.1.13",
|
||||||
"rollup": "^1.17.0",
|
"rollup": "^1.17.0",
|
||||||
"rollup-plugin-node-resolve": "^5.2.0",
|
"rollup-plugin-node-resolve": "^5.2.0",
|
||||||
"rollup-watch": "^4.3.1",
|
"rollup-watch": "^4.3.1",
|
||||||
"tslib": "^1.10.0",
|
"tslib": "^1.10.0",
|
||||||
"typescript": "^3.5.3"
|
"typescript": "^3.5.3",
|
||||||
|
"ws": "^7.2.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/estree": {
|
"@types/estree": {
|
||||||
@ -320,9 +322,9 @@
|
|||||||
"integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw=="
|
"integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw=="
|
||||||
},
|
},
|
||||||
"@types/node": {
|
"@types/node": {
|
||||||
"version": "12.11.1",
|
"version": "12.11.5",
|
||||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-12.11.1.tgz",
|
"resolved": "https://registry.npmjs.org/@types/node/-/node-12.11.5.tgz",
|
||||||
"integrity": "sha512-TJtwsqZ39pqcljJpajeoofYRfeZ7/I/OMUQ5pR4q5wOKf2ocrUvBAZUMhWsOvKx3dVc/aaV5GluBivt0sWqA5A=="
|
"integrity": "sha512-LC8ALj/24PhByn39nr5jnTvpE7MujK8y7LQmV74kHYF5iQ0odCPkMH4IZNZw+cobKfSXqaC8GgegcbIsQpffdA=="
|
||||||
},
|
},
|
||||||
"@types/resolve": {
|
"@types/resolve": {
|
||||||
"version": "0.0.8",
|
"version": "0.0.8",
|
||||||
@ -332,6 +334,14 @@
|
|||||||
"@types/node": "*"
|
"@types/node": "*"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"@types/ws": {
|
||||||
|
"version": "6.0.3",
|
||||||
|
"resolved": "https://registry.npmjs.org/@types/ws/-/ws-6.0.3.tgz",
|
||||||
|
"integrity": "sha512-yBTM0P05Tx9iXGq00BbJPo37ox68R5vaGTXivs6RGh/BQ6QP5zqZDGWdAO6JbRE/iR1l80xeGAwCQS2nMV9S/w==",
|
||||||
|
"requires": {
|
||||||
|
"@types/node": "*"
|
||||||
|
}
|
||||||
|
},
|
||||||
"acorn": {
|
"acorn": {
|
||||||
"version": "7.1.0",
|
"version": "7.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/acorn/-/acorn-7.1.0.tgz",
|
"resolved": "https://registry.npmjs.org/acorn/-/acorn-7.1.0.tgz",
|
||||||
@ -379,6 +389,11 @@
|
|||||||
"resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.3.tgz",
|
"resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.3.tgz",
|
||||||
"integrity": "sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ=="
|
"integrity": "sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ=="
|
||||||
},
|
},
|
||||||
|
"async-limiter": {
|
||||||
|
"version": "1.0.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz",
|
||||||
|
"integrity": "sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ=="
|
||||||
|
},
|
||||||
"atob": {
|
"atob": {
|
||||||
"version": "2.1.2",
|
"version": "2.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz",
|
"resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz",
|
||||||
@ -2041,9 +2056,9 @@
|
|||||||
"integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg=="
|
"integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg=="
|
||||||
},
|
},
|
||||||
"rollup": {
|
"rollup": {
|
||||||
"version": "1.25.1",
|
"version": "1.25.2",
|
||||||
"resolved": "https://registry.npmjs.org/rollup/-/rollup-1.25.1.tgz",
|
"resolved": "https://registry.npmjs.org/rollup/-/rollup-1.25.2.tgz",
|
||||||
"integrity": "sha512-K8ytdEzMa6anHSnfTIs2BLB+NXlQ4qmWwdNHBpYQNWCbZAzj+DRVk7+ssbLSgddwpFW1nThr2GElR+jASF2NPA==",
|
"integrity": "sha512-+7z6Wab/L45QCPcfpuTZKwKiB0tynj05s/+s2U3F2Bi7rOLPr9UcjUwO7/xpjlPNXA/hwnth6jBExFRGyf3tMg==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"@types/estree": "*",
|
"@types/estree": "*",
|
||||||
"@types/node": "*",
|
"@types/node": "*",
|
||||||
@ -2382,6 +2397,14 @@
|
|||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
|
"resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
|
||||||
"integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8="
|
"integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8="
|
||||||
|
},
|
||||||
|
"ws": {
|
||||||
|
"version": "7.2.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/ws/-/ws-7.2.0.tgz",
|
||||||
|
"integrity": "sha512-+SqNqFbwTm/0DC18KYzIsMTnEWpLwJsiasW/O17la4iDRRIO9uaHbvKiAS3AHgTiuuWerK/brj4O6MYZkei9xg==",
|
||||||
|
"requires": {
|
||||||
|
"async-limiter": "^1.0.0"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -2483,26 +2506,22 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"abbrev": {
|
"abbrev": {
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"ansi-regex": {
|
"ansi-regex": {
|
||||||
"version": "2.1.1",
|
"version": "2.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"aproba": {
|
"aproba": {
|
||||||
"version": "1.2.0",
|
"version": "1.2.0",
|
||||||
"resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"are-we-there-yet": {
|
"are-we-there-yet": {
|
||||||
"version": "1.1.5",
|
"version": "1.1.5",
|
||||||
"resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-5hYdAkZlcG8tOLujVDTgCT+uPX0VnpAH28gWsLfzpXYm7wP6mp5Q/gYyR7YQ0cKVJcXJnl3j2kpBan13PtQf6w==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"delegates": "^1.0.0",
|
"delegates": "^1.0.0",
|
||||||
@ -2511,14 +2530,12 @@
|
|||||||
},
|
},
|
||||||
"balanced-match": {
|
"balanced-match": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"brace-expansion": {
|
"brace-expansion": {
|
||||||
"version": "1.1.11",
|
"version": "1.1.11",
|
||||||
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"balanced-match": "^1.0.0",
|
"balanced-match": "^1.0.0",
|
||||||
@ -2527,38 +2544,32 @@
|
|||||||
},
|
},
|
||||||
"chownr": {
|
"chownr": {
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-j38EvO5+LHX84jlo6h4UzmOwi0UgW61WRyPtJz4qaadK5eY3BTS5TY/S1Stc3Uk2lIM6TPevAlULiEJwie860g==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"code-point-at": {
|
"code-point-at": {
|
||||||
"version": "1.1.0",
|
"version": "1.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"concat-map": {
|
"concat-map": {
|
||||||
"version": "0.0.1",
|
"version": "0.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"console-control-strings": {
|
"console-control-strings": {
|
||||||
"version": "1.1.0",
|
"version": "1.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"core-util-is": {
|
"core-util-is": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"debug": {
|
"debug": {
|
||||||
"version": "4.1.1",
|
"version": "4.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"ms": "^2.1.1"
|
"ms": "^2.1.1"
|
||||||
@ -2566,26 +2577,22 @@
|
|||||||
},
|
},
|
||||||
"deep-extend": {
|
"deep-extend": {
|
||||||
"version": "0.6.0",
|
"version": "0.6.0",
|
||||||
"resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"delegates": {
|
"delegates": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"detect-libc": {
|
"detect-libc": {
|
||||||
"version": "1.0.3",
|
"version": "1.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-+hN8S9aY7fVc1c0CrFWfkaTEups=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"fs-minipass": {
|
"fs-minipass": {
|
||||||
"version": "1.2.5",
|
"version": "1.2.5",
|
||||||
"resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-1.2.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-JhBl0skXjUPCFH7x6x61gQxrKyXsxB5gcgePLZCwfyCGGsTISMoIeObbrvVeP6Xmyaudw4TT43qV2Gz+iyd2oQ==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"minipass": "^2.2.1"
|
"minipass": "^2.2.1"
|
||||||
@ -2593,14 +2600,12 @@
|
|||||||
},
|
},
|
||||||
"fs.realpath": {
|
"fs.realpath": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"gauge": {
|
"gauge": {
|
||||||
"version": "2.7.4",
|
"version": "2.7.4",
|
||||||
"resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"aproba": "^1.0.3",
|
"aproba": "^1.0.3",
|
||||||
@ -2615,8 +2620,7 @@
|
|||||||
},
|
},
|
||||||
"glob": {
|
"glob": {
|
||||||
"version": "7.1.3",
|
"version": "7.1.3",
|
||||||
"resolved": "https://registry.npmjs.org/glob/-/glob-7.1.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"fs.realpath": "^1.0.0",
|
"fs.realpath": "^1.0.0",
|
||||||
@ -2629,14 +2633,12 @@
|
|||||||
},
|
},
|
||||||
"has-unicode": {
|
"has-unicode": {
|
||||||
"version": "2.0.1",
|
"version": "2.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"iconv-lite": {
|
"iconv-lite": {
|
||||||
"version": "0.4.24",
|
"version": "0.4.24",
|
||||||
"resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"safer-buffer": ">= 2.1.2 < 3"
|
"safer-buffer": ">= 2.1.2 < 3"
|
||||||
@ -2644,8 +2646,7 @@
|
|||||||
},
|
},
|
||||||
"ignore-walk": {
|
"ignore-walk": {
|
||||||
"version": "3.0.1",
|
"version": "3.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/ignore-walk/-/ignore-walk-3.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-DTVlMx3IYPe0/JJcYP7Gxg7ttZZu3IInhuEhbchuqneY9wWe5Ojy2mXLBaQFUQmo0AW2r3qG7m1mg86js+gnlQ==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"minimatch": "^3.0.4"
|
"minimatch": "^3.0.4"
|
||||||
@ -2653,8 +2654,7 @@
|
|||||||
},
|
},
|
||||||
"inflight": {
|
"inflight": {
|
||||||
"version": "1.0.6",
|
"version": "1.0.6",
|
||||||
"resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"once": "^1.3.0",
|
"once": "^1.3.0",
|
||||||
@ -2663,20 +2663,17 @@
|
|||||||
},
|
},
|
||||||
"inherits": {
|
"inherits": {
|
||||||
"version": "2.0.3",
|
"version": "2.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"ini": {
|
"ini": {
|
||||||
"version": "1.3.5",
|
"version": "1.3.5",
|
||||||
"resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"is-fullwidth-code-point": {
|
"is-fullwidth-code-point": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"number-is-nan": "^1.0.0"
|
"number-is-nan": "^1.0.0"
|
||||||
@ -2684,14 +2681,12 @@
|
|||||||
},
|
},
|
||||||
"isarray": {
|
"isarray": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"minimatch": {
|
"minimatch": {
|
||||||
"version": "3.0.4",
|
"version": "3.0.4",
|
||||||
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"brace-expansion": "^1.1.7"
|
"brace-expansion": "^1.1.7"
|
||||||
@ -2699,14 +2694,12 @@
|
|||||||
},
|
},
|
||||||
"minimist": {
|
"minimist": {
|
||||||
"version": "0.0.8",
|
"version": "0.0.8",
|
||||||
"resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"minipass": {
|
"minipass": {
|
||||||
"version": "2.3.5",
|
"version": "2.3.5",
|
||||||
"resolved": "https://registry.npmjs.org/minipass/-/minipass-2.3.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"safe-buffer": "^5.1.2",
|
"safe-buffer": "^5.1.2",
|
||||||
@ -2715,8 +2708,7 @@
|
|||||||
},
|
},
|
||||||
"minizlib": {
|
"minizlib": {
|
||||||
"version": "1.2.1",
|
"version": "1.2.1",
|
||||||
"resolved": "https://registry.npmjs.org/minizlib/-/minizlib-1.2.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-7+4oTUOWKg7AuL3vloEWekXY2/D20cevzsrNT2kGWm+39J9hGTCBv8VI5Pm5lXZ/o3/mdR4f8rflAPhnQb8mPA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"minipass": "^2.2.1"
|
"minipass": "^2.2.1"
|
||||||
@ -2724,8 +2716,7 @@
|
|||||||
},
|
},
|
||||||
"mkdirp": {
|
"mkdirp": {
|
||||||
"version": "0.5.1",
|
"version": "0.5.1",
|
||||||
"resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"minimist": "0.0.8"
|
"minimist": "0.0.8"
|
||||||
@ -2733,14 +2724,12 @@
|
|||||||
},
|
},
|
||||||
"ms": {
|
"ms": {
|
||||||
"version": "2.1.1",
|
"version": "2.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"needle": {
|
"needle": {
|
||||||
"version": "2.3.0",
|
"version": "2.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/needle/-/needle-2.3.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-QBZu7aAFR0522EyaXZM0FZ9GLpq6lvQ3uq8gteiDUp7wKdy0lSd2hPlgFwVuW1CBkfEs9PfDQsQzZghLs/psdg==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"debug": "^4.1.0",
|
"debug": "^4.1.0",
|
||||||
@ -2750,8 +2739,7 @@
|
|||||||
},
|
},
|
||||||
"node-pre-gyp": {
|
"node-pre-gyp": {
|
||||||
"version": "0.12.0",
|
"version": "0.12.0",
|
||||||
"resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.12.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-4KghwV8vH5k+g2ylT+sLTjy5wmUOb9vPhnM8NHvRf9dHmnW/CndrFXy2aRPaPST6dugXSdHXfeaHQm77PIz/1A==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"detect-libc": "^1.0.2",
|
"detect-libc": "^1.0.2",
|
||||||
@ -2768,8 +2756,7 @@
|
|||||||
},
|
},
|
||||||
"nopt": {
|
"nopt": {
|
||||||
"version": "4.0.1",
|
"version": "4.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-0NRoWv1UFRk8jHUFYC0NF81kR00=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"abbrev": "1",
|
"abbrev": "1",
|
||||||
@ -2778,14 +2765,12 @@
|
|||||||
},
|
},
|
||||||
"npm-bundled": {
|
"npm-bundled": {
|
||||||
"version": "1.0.6",
|
"version": "1.0.6",
|
||||||
"resolved": "https://registry.npmjs.org/npm-bundled/-/npm-bundled-1.0.6.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-8/JCaftHwbd//k6y2rEWp6k1wxVfpFzB6t1p825+cUb7Ym2XQfhwIC5KwhrvzZRJu+LtDE585zVaS32+CGtf0g==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"npm-packlist": {
|
"npm-packlist": {
|
||||||
"version": "1.4.1",
|
"version": "1.4.1",
|
||||||
"resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-1.4.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-+TcdO7HJJ8peiiYhvPxsEDhF3PJFGUGRcFsGve3vxvxdcpO2Z4Z7rkosRM0kWj6LfbK/P0gu3dzk5RU1ffvFcw==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"ignore-walk": "^3.0.1",
|
"ignore-walk": "^3.0.1",
|
||||||
@ -2794,8 +2779,7 @@
|
|||||||
},
|
},
|
||||||
"npmlog": {
|
"npmlog": {
|
||||||
"version": "4.1.2",
|
"version": "4.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"are-we-there-yet": "~1.1.2",
|
"are-we-there-yet": "~1.1.2",
|
||||||
@ -2806,20 +2790,17 @@
|
|||||||
},
|
},
|
||||||
"number-is-nan": {
|
"number-is-nan": {
|
||||||
"version": "1.0.1",
|
"version": "1.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"object-assign": {
|
"object-assign": {
|
||||||
"version": "4.1.1",
|
"version": "4.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"once": {
|
"once": {
|
||||||
"version": "1.4.0",
|
"version": "1.4.0",
|
||||||
"resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"wrappy": "1"
|
"wrappy": "1"
|
||||||
@ -2827,20 +2808,17 @@
|
|||||||
},
|
},
|
||||||
"os-homedir": {
|
"os-homedir": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"os-tmpdir": {
|
"os-tmpdir": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"osenv": {
|
"osenv": {
|
||||||
"version": "0.1.5",
|
"version": "0.1.5",
|
||||||
"resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"os-homedir": "^1.0.0",
|
"os-homedir": "^1.0.0",
|
||||||
@ -2849,20 +2827,17 @@
|
|||||||
},
|
},
|
||||||
"path-is-absolute": {
|
"path-is-absolute": {
|
||||||
"version": "1.0.1",
|
"version": "1.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"process-nextick-args": {
|
"process-nextick-args": {
|
||||||
"version": "2.0.0",
|
"version": "2.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"rc": {
|
"rc": {
|
||||||
"version": "1.2.8",
|
"version": "1.2.8",
|
||||||
"resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"deep-extend": "^0.6.0",
|
"deep-extend": "^0.6.0",
|
||||||
@ -2873,16 +2848,14 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"minimist": {
|
"minimist": {
|
||||||
"version": "1.2.0",
|
"version": "1.2.0",
|
||||||
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"readable-stream": {
|
"readable-stream": {
|
||||||
"version": "2.3.6",
|
"version": "2.3.6",
|
||||||
"resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"core-util-is": "~1.0.0",
|
"core-util-is": "~1.0.0",
|
||||||
@ -2896,8 +2869,7 @@
|
|||||||
},
|
},
|
||||||
"rimraf": {
|
"rimraf": {
|
||||||
"version": "2.6.3",
|
"version": "2.6.3",
|
||||||
"resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"glob": "^7.1.3"
|
"glob": "^7.1.3"
|
||||||
@ -2905,44 +2877,37 @@
|
|||||||
},
|
},
|
||||||
"safe-buffer": {
|
"safe-buffer": {
|
||||||
"version": "5.1.2",
|
"version": "5.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"safer-buffer": {
|
"safer-buffer": {
|
||||||
"version": "2.1.2",
|
"version": "2.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"sax": {
|
"sax": {
|
||||||
"version": "1.2.4",
|
"version": "1.2.4",
|
||||||
"resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"semver": {
|
"semver": {
|
||||||
"version": "5.7.0",
|
"version": "5.7.0",
|
||||||
"resolved": "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"set-blocking": {
|
"set-blocking": {
|
||||||
"version": "2.0.0",
|
"version": "2.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"signal-exit": {
|
"signal-exit": {
|
||||||
"version": "3.0.2",
|
"version": "3.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"string-width": {
|
"string-width": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"code-point-at": "^1.0.0",
|
"code-point-at": "^1.0.0",
|
||||||
@ -2952,8 +2917,7 @@
|
|||||||
},
|
},
|
||||||
"string_decoder": {
|
"string_decoder": {
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"safe-buffer": "~5.1.0"
|
"safe-buffer": "~5.1.0"
|
||||||
@ -2961,8 +2925,7 @@
|
|||||||
},
|
},
|
||||||
"strip-ansi": {
|
"strip-ansi": {
|
||||||
"version": "3.0.1",
|
"version": "3.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"ansi-regex": "^2.0.0"
|
"ansi-regex": "^2.0.0"
|
||||||
@ -2970,14 +2933,12 @@
|
|||||||
},
|
},
|
||||||
"strip-json-comments": {
|
"strip-json-comments": {
|
||||||
"version": "2.0.1",
|
"version": "2.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"tar": {
|
"tar": {
|
||||||
"version": "4.4.8",
|
"version": "4.4.8",
|
||||||
"resolved": "https://registry.npmjs.org/tar/-/tar-4.4.8.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-LzHF64s5chPQQS0IYBn9IN5h3i98c12bo4NCO7e0sGM2llXQ3p2FGC5sdENN4cTW48O915Sh+x+EXx7XW96xYQ==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"chownr": "^1.1.1",
|
"chownr": "^1.1.1",
|
||||||
@ -2991,14 +2952,12 @@
|
|||||||
},
|
},
|
||||||
"util-deprecate": {
|
"util-deprecate": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"wide-align": {
|
"wide-align": {
|
||||||
"version": "1.1.3",
|
"version": "1.1.3",
|
||||||
"resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"string-width": "^1.0.2 || 2"
|
"string-width": "^1.0.2 || 2"
|
||||||
@ -3006,14 +2965,12 @@
|
|||||||
},
|
},
|
||||||
"wrappy": {
|
"wrappy": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"yallist": {
|
"yallist": {
|
||||||
"version": "3.0.3",
|
"version": "3.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/yallist/-/yallist-3.0.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-S+Zk8DEWE6oKpV+vI3qWkaK+jSbIK86pCwe2IF/xwIpQ8jEuxpw9NyaGjmp9+BoJv5FV2piqCDcoCtStppiq2A==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -3829,9 +3786,9 @@
|
|||||||
"integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg=="
|
"integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg=="
|
||||||
},
|
},
|
||||||
"rollup": {
|
"rollup": {
|
||||||
"version": "1.25.1",
|
"version": "1.25.2",
|
||||||
"resolved": "https://registry.npmjs.org/rollup/-/rollup-1.25.1.tgz",
|
"resolved": "https://registry.npmjs.org/rollup/-/rollup-1.25.2.tgz",
|
||||||
"integrity": "sha512-K8ytdEzMa6anHSnfTIs2BLB+NXlQ4qmWwdNHBpYQNWCbZAzj+DRVk7+ssbLSgddwpFW1nThr2GElR+jASF2NPA==",
|
"integrity": "sha512-+7z6Wab/L45QCPcfpuTZKwKiB0tynj05s/+s2U3F2Bi7rOLPr9UcjUwO7/xpjlPNXA/hwnth6jBExFRGyf3tMg==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"@types/estree": "*",
|
"@types/estree": "*",
|
||||||
"@types/node": "*",
|
"@types/node": "*",
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
import { vlayout, Image, ViewHolder, VMPanel, ViewModel, Gravity, NativeCall, Text, Color, log, logw, loge, Group, LayoutSpec, } from "doric"
|
import { vlayout, Image, ViewHolder, VMPanel, ViewModel, Gravity, NativeCall, Text, Color, log, logw, loge, Group, LayoutSpec, } from "doric"
|
||||||
|
|
||||||
|
|
||||||
interface CountModel {
|
interface CountModel {
|
||||||
count: number
|
count: number
|
||||||
}
|
}
|
||||||
|
@ -51,7 +51,7 @@ + (instancetype)instance {
|
|||||||
}
|
}
|
||||||
|
|
||||||
- (void)createContext:(DoricContext *)context script:(NSString *)script source:(NSString *)source {
|
- (void)createContext:(DoricContext *)context script:(NSString *)script source:(NSString *)source {
|
||||||
context.contextId = [NSString stringWithFormat:@"%ld", (long) self.counter++];
|
context.contextId = [NSString stringWithFormat:@"%ld", (long) ++self.counter];
|
||||||
[context.driver createContext:context.contextId script:script source:source];
|
[context.driver createContext:context.contextId script:script source:source];
|
||||||
dispatch_sync(self.mapQueue, ^() {
|
dispatch_sync(self.mapQueue, ^() {
|
||||||
NSValue *value = [NSValue valueWithNonretainedObject:context];
|
NSValue *value = [NSValue valueWithNonretainedObject:context];
|
||||||
|
@ -23,6 +23,7 @@
|
|||||||
#import "DoricJSEngine.h"
|
#import "DoricJSEngine.h"
|
||||||
#import "DoricJSExecutorProtocal.h"
|
#import "DoricJSExecutorProtocal.h"
|
||||||
#import "DoricJSCoreExecutor.h"
|
#import "DoricJSCoreExecutor.h"
|
||||||
|
#import "DoricJSRemoteExecutor.h"
|
||||||
#import "DoricConstant.h"
|
#import "DoricConstant.h"
|
||||||
#import "DoricUtil.h"
|
#import "DoricUtil.h"
|
||||||
#import "DoricBridgeExtension.h"
|
#import "DoricBridgeExtension.h"
|
||||||
@ -41,7 +42,9 @@ - (instancetype)init {
|
|||||||
_bridgeExtension = [[DoricBridgeExtension alloc] init];
|
_bridgeExtension = [[DoricBridgeExtension alloc] init];
|
||||||
dispatch_async(_jsQueue, ^() {
|
dispatch_async(_jsQueue, ^() {
|
||||||
self.timers = [[NSMutableDictionary alloc] init];
|
self.timers = [[NSMutableDictionary alloc] init];
|
||||||
self.jsExecutor = [[DoricJSCoreExecutor alloc] init];
|
// Debug: 切换
|
||||||
|
// self.jsExecutor = [[DoricJSRemoteExecutor alloc] init];
|
||||||
|
self.jsExecutor = [DoricJSCoreExecutor new];
|
||||||
self.registry = [[DoricRegistry alloc] init];
|
self.registry = [[DoricRegistry alloc] init];
|
||||||
[self initJSExecutor];
|
[self initJSExecutor];
|
||||||
[self initDoricEnvironment];
|
[self initDoricEnvironment];
|
||||||
|
35
iOS/Pod/Classes/Engine/DoricJSRemoteExecutor.h
Normal file
35
iOS/Pod/Classes/Engine/DoricJSRemoteExecutor.h
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
/*
|
||||||
|
* Copyright [2019] [Doric.Pub]
|
||||||
|
*
|
||||||
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
* you may not use this file except in compliance with the License.
|
||||||
|
* You may obtain a copy of the License at
|
||||||
|
*
|
||||||
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
*
|
||||||
|
* Unless required by applicable law or agreed to in writing, software
|
||||||
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
* See the License for the specific language governing permissions and
|
||||||
|
* limitations under the License.
|
||||||
|
*/
|
||||||
|
//
|
||||||
|
// DoricJSRemoteExecutor.h
|
||||||
|
// Pods
|
||||||
|
//
|
||||||
|
// Created by 王劲鹏 on 2019/10/31.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import <Foundation/Foundation.h>
|
||||||
|
#import "DoricJSExecutorProtocal.h"
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
|
|
||||||
|
@interface DoricJSRemoteExecutor : NSObject <DoricJSExecutorProtocal>
|
||||||
|
|
||||||
|
@property(nonatomic, strong) dispatch_semaphore_t semaphore;
|
||||||
|
|
||||||
|
- (void)close;
|
||||||
|
@end
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_END
|
193
iOS/Pod/Classes/Engine/DoricJSRemoteExecutor.m
Normal file
193
iOS/Pod/Classes/Engine/DoricJSRemoteExecutor.m
Normal file
@ -0,0 +1,193 @@
|
|||||||
|
/*
|
||||||
|
* Copyright [2019] [Doric.Pub]
|
||||||
|
*
|
||||||
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
* you may not use this file except in compliance with the License.
|
||||||
|
* You may obtain a copy of the License at
|
||||||
|
*
|
||||||
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
*
|
||||||
|
* Unless required by applicable law or agreed to in writing, software
|
||||||
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
* See the License for the specific language governing permissions and
|
||||||
|
* limitations under the License.
|
||||||
|
*/
|
||||||
|
//
|
||||||
|
// DoricJSRemoteExecutor.m
|
||||||
|
// Doric
|
||||||
|
//
|
||||||
|
// Created by 王劲鹏 on 2019/10/31.
|
||||||
|
//
|
||||||
|
#import "DoricJSRemoteExecutor.h"
|
||||||
|
#import <SocketRocket/SRWebSocket.h>
|
||||||
|
#import "DoricUtil.h"
|
||||||
|
#import "DoricJSRemoteArgType.h"
|
||||||
|
#import "NSString+JsonString.h"
|
||||||
|
|
||||||
|
static NSString * const kUrlStr = @"ws://192.168.24.240:2080";
|
||||||
|
|
||||||
|
typedef id (^Block0)(void);
|
||||||
|
typedef id (^Block1)(id arg0);
|
||||||
|
typedef id (^Block2)(id arg0, id arg1);
|
||||||
|
typedef id (^Block3)(id arg0, id arg1, id arg2);
|
||||||
|
typedef id (^Block4)(id arg0, id arg1, id arg2, id arg3);
|
||||||
|
typedef id (^Block5)(id arg0, id arg1, id arg2, id arg3, id arg4);
|
||||||
|
|
||||||
|
@interface DoricJSRemoteExecutor () <SRWebSocketDelegate>
|
||||||
|
@property(nonatomic, strong) SRWebSocket *srWebSocket;
|
||||||
|
@property(nonatomic, strong) NSMutableDictionary <NSString *, id> *blockMDic;
|
||||||
|
@property(nonatomic, strong) JSValue *temp;
|
||||||
|
@end
|
||||||
|
|
||||||
|
@implementation DoricJSRemoteExecutor
|
||||||
|
- (instancetype)init {
|
||||||
|
if (self = [super init]) {
|
||||||
|
[self srWebSocket];
|
||||||
|
_semaphore = dispatch_semaphore_create(0);
|
||||||
|
DC_LOCK(self.semaphore);
|
||||||
|
}
|
||||||
|
return self;
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)webSocketDidOpen:(SRWebSocket *)webSocket {
|
||||||
|
DoricLog(@"debugger webSocketDidOpen");
|
||||||
|
DC_UNLOCK(self.semaphore);
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)webSocket:(SRWebSocket *)webSocket didReceivePong:(NSData *)pongPayload {
|
||||||
|
DoricLog(@"debugger webSocketdidReceivePong");
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)webSocket:(SRWebSocket *)webSocket didReceiveMessage:(id)message {
|
||||||
|
NSData *jsonData = [message dataUsingEncoding:NSUTF8StringEncoding];
|
||||||
|
NSError *err;
|
||||||
|
NSDictionary *dic = [NSJSONSerialization JSONObjectWithData:jsonData
|
||||||
|
options:NSJSONReadingMutableContainers
|
||||||
|
error:&err];
|
||||||
|
if (err) {
|
||||||
|
DoricLog(@"debugger webSocketdidReceiveMessage parse error:%@", err);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
NSString *cmd = [[dic valueForKey:@"cmd"] copy];
|
||||||
|
|
||||||
|
if ([cmd isEqualToString:@"injectGlobalJSFunction"]) {
|
||||||
|
NSString *name = [dic valueForKey:@"name"];
|
||||||
|
NSArray *argsArr = [dic valueForKey:@"arguments"];
|
||||||
|
NSMutableArray *argsMarr = [NSMutableArray new];
|
||||||
|
for (NSUInteger i = 0; i < argsArr.count; i++) {
|
||||||
|
[argsMarr addObject:argsArr[i]];
|
||||||
|
}
|
||||||
|
|
||||||
|
id result;
|
||||||
|
id tmpBlk = self.blockMDic[name];
|
||||||
|
if (argsArr.count == 0) {
|
||||||
|
result = ((Block0) tmpBlk)();
|
||||||
|
} else if (argsArr.count == 1) {
|
||||||
|
result = ((Block1) tmpBlk)(argsArr[0]);
|
||||||
|
} else if (argsArr.count == 2) {
|
||||||
|
result = ((Block2)tmpBlk)(argsArr[0], argsArr[1]);
|
||||||
|
} else if (argsArr.count == 3) {
|
||||||
|
result = ((Block3)tmpBlk)(argsArr[0], argsArr[1], argsArr[2]);
|
||||||
|
} else if (argsArr.count == 4) {
|
||||||
|
result = ((Block4)tmpBlk)(argsArr[0], argsArr[1], argsArr[2], argsArr[3]);
|
||||||
|
} else if (argsArr.count == 5) {
|
||||||
|
result = ((Block5)tmpBlk)(argsArr[0], argsArr[1], argsArr[2], argsArr[3], argsArr[4]);
|
||||||
|
}
|
||||||
|
|
||||||
|
} else if ([cmd isEqualToString:@"invokeMethod"]) {
|
||||||
|
@try {
|
||||||
|
self.temp = [JSValue valueWithObject:[dic valueForKey:@"result"] inContext:nil];
|
||||||
|
} @catch (NSException *exception) {
|
||||||
|
DoricLog(@"debugger ", NSStringFromSelector(_cmd), exception.reason);
|
||||||
|
} @finally {
|
||||||
|
DC_UNLOCK(self.semaphore);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)webSocket:(SRWebSocket *)webSocket didFailWithError:(NSError *)error {
|
||||||
|
DoricLog(@"debugger webSocketdidFailWithError");
|
||||||
|
DC_UNLOCK(self.semaphore);
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)webSocket:(SRWebSocket *)webSocket didCloseWithCode:(NSInteger)code reason:(NSString *)reason wasClean:(BOOL)wasClean {
|
||||||
|
DoricLog(@"debugger webSocketdidCloseWithCode");
|
||||||
|
}
|
||||||
|
|
||||||
|
- (NSString *)loadJSScript:(NSString *)script source:(NSString *)source {
|
||||||
|
|
||||||
|
return nil;
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)injectGlobalJSObject:(NSString *)name obj:(id)obj {
|
||||||
|
if ([obj isKindOfClass:NSClassFromString(@"NSBlock")]) {
|
||||||
|
self.blockMDic[name] = obj;
|
||||||
|
}
|
||||||
|
NSDictionary *jsonDic = @{
|
||||||
|
@"cmd": @"injectGlobalJSFunction",
|
||||||
|
@"name": name
|
||||||
|
};
|
||||||
|
|
||||||
|
NSString *jsonStr = [NSString dc_convertToJsonWithDic:jsonDic];
|
||||||
|
if (!jsonStr) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
[self.srWebSocket send:jsonStr];
|
||||||
|
}
|
||||||
|
|
||||||
|
- (JSValue *)invokeObject:(NSString *)objName method:(NSString *)funcName args:(NSArray *)args {
|
||||||
|
|
||||||
|
NSMutableArray *argsMArr = [NSMutableArray new];
|
||||||
|
for (id arg in args) {
|
||||||
|
NSDictionary *dic = @{
|
||||||
|
@"type": @(DoricargTypeWithArg(arg)),
|
||||||
|
@"value": arg
|
||||||
|
};
|
||||||
|
[argsMArr addObject:dic];
|
||||||
|
}
|
||||||
|
|
||||||
|
NSArray *argsArr = [argsMArr copy];
|
||||||
|
|
||||||
|
NSDictionary *jsonDic = @{
|
||||||
|
@"cmd": @"invokeMethod",
|
||||||
|
@"objectName": objName,
|
||||||
|
@"functionName": funcName,
|
||||||
|
@"javaValues": argsArr
|
||||||
|
};
|
||||||
|
|
||||||
|
NSString *jsonStr = [NSString dc_convertToJsonWithDic:jsonDic];
|
||||||
|
if (!jsonStr) {
|
||||||
|
return nil;
|
||||||
|
}
|
||||||
|
|
||||||
|
[self.srWebSocket send:jsonStr];
|
||||||
|
DC_LOCK(self.semaphore);
|
||||||
|
|
||||||
|
return self.temp;
|
||||||
|
}
|
||||||
|
|
||||||
|
- (void)close {
|
||||||
|
[self.srWebSocket close];
|
||||||
|
}
|
||||||
|
|
||||||
|
#pragma mark - Properties
|
||||||
|
- (SRWebSocket *)srWebSocket {
|
||||||
|
if (!_srWebSocket) {
|
||||||
|
NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:kUrlStr] cachePolicy:NSURLRequestReloadIgnoringLocalAndRemoteCacheData timeoutInterval:10];
|
||||||
|
_srWebSocket = [[SRWebSocket alloc] initWithURLRequest:request];
|
||||||
|
_srWebSocket.delegate = self;
|
||||||
|
[_srWebSocket open];
|
||||||
|
}
|
||||||
|
return _srWebSocket;
|
||||||
|
}
|
||||||
|
|
||||||
|
- (NSMutableDictionary *)blockMDic {
|
||||||
|
if (!_blockMDic) {
|
||||||
|
_blockMDic = [NSMutableDictionary new];
|
||||||
|
}
|
||||||
|
return _blockMDic;
|
||||||
|
}
|
||||||
|
|
||||||
|
@end
|
18
iOS/Pod/Classes/Util/Category/NSString+JsonString.h
Normal file
18
iOS/Pod/Classes/Util/Category/NSString+JsonString.h
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
//
|
||||||
|
// NSString+JsonString.h
|
||||||
|
// Doric
|
||||||
|
//
|
||||||
|
// Created by Insomnia on 2019/11/7.
|
||||||
|
//
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#import <Foundation/Foundation.h>
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
|
|
||||||
|
@interface NSString (JsonString)
|
||||||
|
+ (NSString *)dc_convertToJsonWithDic:(NSDictionary *)dic;
|
||||||
|
@end
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_END
|
23
iOS/Pod/Classes/Util/Category/NSString+JsonString.m
Normal file
23
iOS/Pod/Classes/Util/Category/NSString+JsonString.m
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
//
|
||||||
|
// NSString+JsonString.m
|
||||||
|
// Doric
|
||||||
|
//
|
||||||
|
// Created by Insomnia on 2019/11/7.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import "NSString+JsonString.h"
|
||||||
|
#import "DoricUtil.h"
|
||||||
|
|
||||||
|
@implementation NSString (JsonString)
|
||||||
|
+ (NSString *)dc_convertToJsonWithDic:(NSDictionary *)dic {
|
||||||
|
NSError *err;
|
||||||
|
NSData *jsonData = [NSJSONSerialization dataWithJSONObject:dic options:NSJSONWritingPrettyPrinted error:&err];
|
||||||
|
NSString *jsonStr = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding];
|
||||||
|
|
||||||
|
if (err) {
|
||||||
|
DoricLog(NSStringFromSelector(_cmd), @"Convert dictionary to json string failed.");
|
||||||
|
return nil;
|
||||||
|
}
|
||||||
|
return jsonStr;
|
||||||
|
}
|
||||||
|
@end
|
23
iOS/Pod/Classes/Util/DoricJSRemoteArgType.h
Normal file
23
iOS/Pod/Classes/Util/DoricJSRemoteArgType.h
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
//
|
||||||
|
// DoricJSRemoteArgType.h
|
||||||
|
// Doric
|
||||||
|
//
|
||||||
|
// Created by Insomnia on 2019/11/7.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import <Foundation/Foundation.h>
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
|
|
||||||
|
typedef NS_ENUM(NSUInteger, DoricJSRemoteArgType) {
|
||||||
|
DoricJSRemoteArgTypeNil = 0,
|
||||||
|
DoricJSRemoteArgTypeInteger,
|
||||||
|
DoricJSRemoteArgTypeBool,
|
||||||
|
DoricJSRemoteArgTypeString,
|
||||||
|
DoricJSRemoteArgTypeObject,
|
||||||
|
DoricJSRemoteArgTypeArray,
|
||||||
|
};
|
||||||
|
|
||||||
|
DoricJSRemoteArgType DoricargTypeWithArg(id arg);
|
||||||
|
|
||||||
|
NS_ASSUME_NONNULL_END
|
12
iOS/Pod/Classes/Util/DoricJSRemoteArgType.m
Normal file
12
iOS/Pod/Classes/Util/DoricJSRemoteArgType.m
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
//
|
||||||
|
// DoricJSRemoteArgType.m
|
||||||
|
// Doric
|
||||||
|
//
|
||||||
|
// Created by Insomnia on 2019/11/7.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import "DoricJSRemoteArgType.h"
|
||||||
|
DoricJSRemoteArgType DoricargTypeWithArg(id arg) {
|
||||||
|
// TODO: 类型缺失
|
||||||
|
return DoricJSRemoteArgTypeString;
|
||||||
|
}
|
@ -27,3 +27,11 @@ void DoricLog(NSString *_Nonnull format, ...);
|
|||||||
UIColor *_Nonnull DoricColor(NSNumber *_Nonnull number);
|
UIColor *_Nonnull DoricColor(NSNumber *_Nonnull number);
|
||||||
|
|
||||||
NSBundle *DoricBundle();
|
NSBundle *DoricBundle();
|
||||||
|
|
||||||
|
#ifndef DC_LOCK
|
||||||
|
#define DC_LOCK(lock) dispatch_semaphore_wait(lock, DISPATCH_TIME_FOREVER);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef DC_UNLOCK
|
||||||
|
#define DC_UNLOCK(lock) dispatch_semaphore_signal(lock);
|
||||||
|
#endif
|
||||||
|
95
js-framework/index.debug.ts
Normal file
95
js-framework/index.debug.ts
Normal file
@ -0,0 +1,95 @@
|
|||||||
|
/*
|
||||||
|
* Copyright [2019] [Doric.Pub]
|
||||||
|
*
|
||||||
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
* you may not use this file except in compliance with the License.
|
||||||
|
* You may obtain a copy of the License at
|
||||||
|
*
|
||||||
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
*
|
||||||
|
* Unless required by applicable law or agreed to in writing, software
|
||||||
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
* See the License for the specific language governing permissions and
|
||||||
|
* limitations under the License.
|
||||||
|
*/
|
||||||
|
import * as doric from './src/runtime/sandbox'
|
||||||
|
import * as WebSocket from 'ws'
|
||||||
|
|
||||||
|
let global = new Function('return this')()
|
||||||
|
global.doric = doric
|
||||||
|
const contextId = "1"
|
||||||
|
global.context = doric.jsObtainContext(contextId)
|
||||||
|
global.Entry = doric.jsObtainEntry(contextId)
|
||||||
|
|
||||||
|
const wss = new WebSocket.Server({ port: 2080 })
|
||||||
|
wss.on('connection', function connection(ws) {
|
||||||
|
console.log('Connected')
|
||||||
|
ws.on('message', function incoming(message: string) {
|
||||||
|
let messageObject = JSON.parse(message)
|
||||||
|
switch (messageObject.cmd) {
|
||||||
|
case "injectGlobalJSFunction":
|
||||||
|
console.log(messageObject.name)
|
||||||
|
Reflect.set(global, messageObject.name, function () {
|
||||||
|
let args = [].slice.call(arguments)
|
||||||
|
console.log("===============================")
|
||||||
|
console.log(args)
|
||||||
|
console.log("===============================")
|
||||||
|
ws.send(JSON.stringify({
|
||||||
|
cmd: 'injectGlobalJSFunction',
|
||||||
|
name: messageObject.name,
|
||||||
|
arguments: args
|
||||||
|
}))
|
||||||
|
})
|
||||||
|
break
|
||||||
|
case "invokeMethod":
|
||||||
|
console.log(messageObject.objectName)
|
||||||
|
console.log(messageObject.functionName)
|
||||||
|
|
||||||
|
let args = []
|
||||||
|
for (let i = 0; i < messageObject.javaValues.length; i++) {
|
||||||
|
let javaValue = messageObject.javaValues[i]
|
||||||
|
if (javaValue.type === 0) {
|
||||||
|
args.push(null)
|
||||||
|
} else if (javaValue.type === 1) {
|
||||||
|
args.push(parseFloat(javaValue.value))
|
||||||
|
} else if (javaValue.type === 2) {
|
||||||
|
args.push((javaValue.value == 'true'))
|
||||||
|
} else if (javaValue.type === 3) {
|
||||||
|
args.push(javaValue.value.toString())
|
||||||
|
} else if (javaValue.type === 4) {
|
||||||
|
args.push(JSON.parse(javaValue.value))
|
||||||
|
} else if (javaValue.type === 5) {
|
||||||
|
args.push(JSON.parse(javaValue.value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
console.log(args)
|
||||||
|
console.log(messageObject.hashKey)
|
||||||
|
|
||||||
|
let object = Reflect.get(global, messageObject.objectName)
|
||||||
|
let method = Reflect.get(object, messageObject.functionName)
|
||||||
|
let result = Reflect.apply(method, undefined, args)
|
||||||
|
|
||||||
|
console.log(result)
|
||||||
|
ws.send(JSON.stringify({
|
||||||
|
cmd: 'invokeMethod',
|
||||||
|
result: result
|
||||||
|
}))
|
||||||
|
break
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
console.log('Start Server')
|
||||||
|
|
||||||
|
global.injectGlobal = (objName: string, obj: string) => {
|
||||||
|
Reflect.set(global, objName, JSON.parse(obj))
|
||||||
|
}
|
||||||
|
|
||||||
|
global.sendToNative = () => {
|
||||||
|
|
||||||
|
}
|
||||||
|
global.receiveFromNative = () => {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
export * from './index'
|
231
js-framework/package-lock.json
generated
231
js-framework/package-lock.json
generated
@ -10,9 +10,9 @@
|
|||||||
"integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw=="
|
"integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw=="
|
||||||
},
|
},
|
||||||
"@types/node": {
|
"@types/node": {
|
||||||
"version": "12.11.1",
|
"version": "12.11.5",
|
||||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-12.11.1.tgz",
|
"resolved": "https://registry.npmjs.org/@types/node/-/node-12.11.5.tgz",
|
||||||
"integrity": "sha512-TJtwsqZ39pqcljJpajeoofYRfeZ7/I/OMUQ5pR4q5wOKf2ocrUvBAZUMhWsOvKx3dVc/aaV5GluBivt0sWqA5A=="
|
"integrity": "sha512-LC8ALj/24PhByn39nr5jnTvpE7MujK8y7LQmV74kHYF5iQ0odCPkMH4IZNZw+cobKfSXqaC8GgegcbIsQpffdA=="
|
||||||
},
|
},
|
||||||
"@types/resolve": {
|
"@types/resolve": {
|
||||||
"version": "0.0.8",
|
"version": "0.0.8",
|
||||||
@ -22,6 +22,14 @@
|
|||||||
"@types/node": "*"
|
"@types/node": "*"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"@types/ws": {
|
||||||
|
"version": "6.0.3",
|
||||||
|
"resolved": "https://registry.npmjs.org/@types/ws/-/ws-6.0.3.tgz",
|
||||||
|
"integrity": "sha512-yBTM0P05Tx9iXGq00BbJPo37ox68R5vaGTXivs6RGh/BQ6QP5zqZDGWdAO6JbRE/iR1l80xeGAwCQS2nMV9S/w==",
|
||||||
|
"requires": {
|
||||||
|
"@types/node": "*"
|
||||||
|
}
|
||||||
|
},
|
||||||
"acorn": {
|
"acorn": {
|
||||||
"version": "7.1.0",
|
"version": "7.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/acorn/-/acorn-7.1.0.tgz",
|
"resolved": "https://registry.npmjs.org/acorn/-/acorn-7.1.0.tgz",
|
||||||
@ -69,6 +77,11 @@
|
|||||||
"resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.3.tgz",
|
"resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.3.tgz",
|
||||||
"integrity": "sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ=="
|
"integrity": "sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ=="
|
||||||
},
|
},
|
||||||
|
"async-limiter": {
|
||||||
|
"version": "1.0.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz",
|
||||||
|
"integrity": "sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ=="
|
||||||
|
},
|
||||||
"atob": {
|
"atob": {
|
||||||
"version": "2.1.2",
|
"version": "2.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz",
|
"resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz",
|
||||||
@ -401,26 +414,22 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"abbrev": {
|
"abbrev": {
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"ansi-regex": {
|
"ansi-regex": {
|
||||||
"version": "2.1.1",
|
"version": "2.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"aproba": {
|
"aproba": {
|
||||||
"version": "1.2.0",
|
"version": "1.2.0",
|
||||||
"resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"are-we-there-yet": {
|
"are-we-there-yet": {
|
||||||
"version": "1.1.5",
|
"version": "1.1.5",
|
||||||
"resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-5hYdAkZlcG8tOLujVDTgCT+uPX0VnpAH28gWsLfzpXYm7wP6mp5Q/gYyR7YQ0cKVJcXJnl3j2kpBan13PtQf6w==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"delegates": "^1.0.0",
|
"delegates": "^1.0.0",
|
||||||
@ -429,14 +438,12 @@
|
|||||||
},
|
},
|
||||||
"balanced-match": {
|
"balanced-match": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"brace-expansion": {
|
"brace-expansion": {
|
||||||
"version": "1.1.11",
|
"version": "1.1.11",
|
||||||
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"balanced-match": "^1.0.0",
|
"balanced-match": "^1.0.0",
|
||||||
@ -445,38 +452,32 @@
|
|||||||
},
|
},
|
||||||
"chownr": {
|
"chownr": {
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-j38EvO5+LHX84jlo6h4UzmOwi0UgW61WRyPtJz4qaadK5eY3BTS5TY/S1Stc3Uk2lIM6TPevAlULiEJwie860g==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"code-point-at": {
|
"code-point-at": {
|
||||||
"version": "1.1.0",
|
"version": "1.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"concat-map": {
|
"concat-map": {
|
||||||
"version": "0.0.1",
|
"version": "0.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"console-control-strings": {
|
"console-control-strings": {
|
||||||
"version": "1.1.0",
|
"version": "1.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"core-util-is": {
|
"core-util-is": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"debug": {
|
"debug": {
|
||||||
"version": "4.1.1",
|
"version": "4.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"ms": "^2.1.1"
|
"ms": "^2.1.1"
|
||||||
@ -484,26 +485,22 @@
|
|||||||
},
|
},
|
||||||
"deep-extend": {
|
"deep-extend": {
|
||||||
"version": "0.6.0",
|
"version": "0.6.0",
|
||||||
"resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"delegates": {
|
"delegates": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"detect-libc": {
|
"detect-libc": {
|
||||||
"version": "1.0.3",
|
"version": "1.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-+hN8S9aY7fVc1c0CrFWfkaTEups=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"fs-minipass": {
|
"fs-minipass": {
|
||||||
"version": "1.2.5",
|
"version": "1.2.5",
|
||||||
"resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-1.2.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-JhBl0skXjUPCFH7x6x61gQxrKyXsxB5gcgePLZCwfyCGGsTISMoIeObbrvVeP6Xmyaudw4TT43qV2Gz+iyd2oQ==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"minipass": "^2.2.1"
|
"minipass": "^2.2.1"
|
||||||
@ -511,14 +508,12 @@
|
|||||||
},
|
},
|
||||||
"fs.realpath": {
|
"fs.realpath": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"gauge": {
|
"gauge": {
|
||||||
"version": "2.7.4",
|
"version": "2.7.4",
|
||||||
"resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"aproba": "^1.0.3",
|
"aproba": "^1.0.3",
|
||||||
@ -533,8 +528,7 @@
|
|||||||
},
|
},
|
||||||
"glob": {
|
"glob": {
|
||||||
"version": "7.1.3",
|
"version": "7.1.3",
|
||||||
"resolved": "https://registry.npmjs.org/glob/-/glob-7.1.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"fs.realpath": "^1.0.0",
|
"fs.realpath": "^1.0.0",
|
||||||
@ -547,14 +541,12 @@
|
|||||||
},
|
},
|
||||||
"has-unicode": {
|
"has-unicode": {
|
||||||
"version": "2.0.1",
|
"version": "2.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"iconv-lite": {
|
"iconv-lite": {
|
||||||
"version": "0.4.24",
|
"version": "0.4.24",
|
||||||
"resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"safer-buffer": ">= 2.1.2 < 3"
|
"safer-buffer": ">= 2.1.2 < 3"
|
||||||
@ -562,8 +554,7 @@
|
|||||||
},
|
},
|
||||||
"ignore-walk": {
|
"ignore-walk": {
|
||||||
"version": "3.0.1",
|
"version": "3.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/ignore-walk/-/ignore-walk-3.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-DTVlMx3IYPe0/JJcYP7Gxg7ttZZu3IInhuEhbchuqneY9wWe5Ojy2mXLBaQFUQmo0AW2r3qG7m1mg86js+gnlQ==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"minimatch": "^3.0.4"
|
"minimatch": "^3.0.4"
|
||||||
@ -571,8 +562,7 @@
|
|||||||
},
|
},
|
||||||
"inflight": {
|
"inflight": {
|
||||||
"version": "1.0.6",
|
"version": "1.0.6",
|
||||||
"resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"once": "^1.3.0",
|
"once": "^1.3.0",
|
||||||
@ -581,20 +571,17 @@
|
|||||||
},
|
},
|
||||||
"inherits": {
|
"inherits": {
|
||||||
"version": "2.0.3",
|
"version": "2.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"ini": {
|
"ini": {
|
||||||
"version": "1.3.5",
|
"version": "1.3.5",
|
||||||
"resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"is-fullwidth-code-point": {
|
"is-fullwidth-code-point": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"number-is-nan": "^1.0.0"
|
"number-is-nan": "^1.0.0"
|
||||||
@ -602,14 +589,12 @@
|
|||||||
},
|
},
|
||||||
"isarray": {
|
"isarray": {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"minimatch": {
|
"minimatch": {
|
||||||
"version": "3.0.4",
|
"version": "3.0.4",
|
||||||
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"brace-expansion": "^1.1.7"
|
"brace-expansion": "^1.1.7"
|
||||||
@ -617,14 +602,12 @@
|
|||||||
},
|
},
|
||||||
"minimist": {
|
"minimist": {
|
||||||
"version": "0.0.8",
|
"version": "0.0.8",
|
||||||
"resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"minipass": {
|
"minipass": {
|
||||||
"version": "2.3.5",
|
"version": "2.3.5",
|
||||||
"resolved": "https://registry.npmjs.org/minipass/-/minipass-2.3.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"safe-buffer": "^5.1.2",
|
"safe-buffer": "^5.1.2",
|
||||||
@ -633,8 +616,7 @@
|
|||||||
},
|
},
|
||||||
"minizlib": {
|
"minizlib": {
|
||||||
"version": "1.2.1",
|
"version": "1.2.1",
|
||||||
"resolved": "https://registry.npmjs.org/minizlib/-/minizlib-1.2.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-7+4oTUOWKg7AuL3vloEWekXY2/D20cevzsrNT2kGWm+39J9hGTCBv8VI5Pm5lXZ/o3/mdR4f8rflAPhnQb8mPA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"minipass": "^2.2.1"
|
"minipass": "^2.2.1"
|
||||||
@ -642,8 +624,7 @@
|
|||||||
},
|
},
|
||||||
"mkdirp": {
|
"mkdirp": {
|
||||||
"version": "0.5.1",
|
"version": "0.5.1",
|
||||||
"resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"minimist": "0.0.8"
|
"minimist": "0.0.8"
|
||||||
@ -651,14 +632,12 @@
|
|||||||
},
|
},
|
||||||
"ms": {
|
"ms": {
|
||||||
"version": "2.1.1",
|
"version": "2.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"needle": {
|
"needle": {
|
||||||
"version": "2.3.0",
|
"version": "2.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/needle/-/needle-2.3.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-QBZu7aAFR0522EyaXZM0FZ9GLpq6lvQ3uq8gteiDUp7wKdy0lSd2hPlgFwVuW1CBkfEs9PfDQsQzZghLs/psdg==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"debug": "^4.1.0",
|
"debug": "^4.1.0",
|
||||||
@ -668,8 +647,7 @@
|
|||||||
},
|
},
|
||||||
"node-pre-gyp": {
|
"node-pre-gyp": {
|
||||||
"version": "0.12.0",
|
"version": "0.12.0",
|
||||||
"resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.12.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-4KghwV8vH5k+g2ylT+sLTjy5wmUOb9vPhnM8NHvRf9dHmnW/CndrFXy2aRPaPST6dugXSdHXfeaHQm77PIz/1A==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"detect-libc": "^1.0.2",
|
"detect-libc": "^1.0.2",
|
||||||
@ -686,8 +664,7 @@
|
|||||||
},
|
},
|
||||||
"nopt": {
|
"nopt": {
|
||||||
"version": "4.0.1",
|
"version": "4.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-0NRoWv1UFRk8jHUFYC0NF81kR00=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"abbrev": "1",
|
"abbrev": "1",
|
||||||
@ -696,14 +673,12 @@
|
|||||||
},
|
},
|
||||||
"npm-bundled": {
|
"npm-bundled": {
|
||||||
"version": "1.0.6",
|
"version": "1.0.6",
|
||||||
"resolved": "https://registry.npmjs.org/npm-bundled/-/npm-bundled-1.0.6.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-8/JCaftHwbd//k6y2rEWp6k1wxVfpFzB6t1p825+cUb7Ym2XQfhwIC5KwhrvzZRJu+LtDE585zVaS32+CGtf0g==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"npm-packlist": {
|
"npm-packlist": {
|
||||||
"version": "1.4.1",
|
"version": "1.4.1",
|
||||||
"resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-1.4.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-+TcdO7HJJ8peiiYhvPxsEDhF3PJFGUGRcFsGve3vxvxdcpO2Z4Z7rkosRM0kWj6LfbK/P0gu3dzk5RU1ffvFcw==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"ignore-walk": "^3.0.1",
|
"ignore-walk": "^3.0.1",
|
||||||
@ -712,8 +687,7 @@
|
|||||||
},
|
},
|
||||||
"npmlog": {
|
"npmlog": {
|
||||||
"version": "4.1.2",
|
"version": "4.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"are-we-there-yet": "~1.1.2",
|
"are-we-there-yet": "~1.1.2",
|
||||||
@ -724,20 +698,17 @@
|
|||||||
},
|
},
|
||||||
"number-is-nan": {
|
"number-is-nan": {
|
||||||
"version": "1.0.1",
|
"version": "1.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"object-assign": {
|
"object-assign": {
|
||||||
"version": "4.1.1",
|
"version": "4.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"once": {
|
"once": {
|
||||||
"version": "1.4.0",
|
"version": "1.4.0",
|
||||||
"resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"wrappy": "1"
|
"wrappy": "1"
|
||||||
@ -745,20 +716,17 @@
|
|||||||
},
|
},
|
||||||
"os-homedir": {
|
"os-homedir": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"os-tmpdir": {
|
"os-tmpdir": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"osenv": {
|
"osenv": {
|
||||||
"version": "0.1.5",
|
"version": "0.1.5",
|
||||||
"resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"os-homedir": "^1.0.0",
|
"os-homedir": "^1.0.0",
|
||||||
@ -767,20 +735,17 @@
|
|||||||
},
|
},
|
||||||
"path-is-absolute": {
|
"path-is-absolute": {
|
||||||
"version": "1.0.1",
|
"version": "1.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"process-nextick-args": {
|
"process-nextick-args": {
|
||||||
"version": "2.0.0",
|
"version": "2.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"rc": {
|
"rc": {
|
||||||
"version": "1.2.8",
|
"version": "1.2.8",
|
||||||
"resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"deep-extend": "^0.6.0",
|
"deep-extend": "^0.6.0",
|
||||||
@ -791,16 +756,14 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"minimist": {
|
"minimist": {
|
||||||
"version": "1.2.0",
|
"version": "1.2.0",
|
||||||
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"readable-stream": {
|
"readable-stream": {
|
||||||
"version": "2.3.6",
|
"version": "2.3.6",
|
||||||
"resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"core-util-is": "~1.0.0",
|
"core-util-is": "~1.0.0",
|
||||||
@ -814,8 +777,7 @@
|
|||||||
},
|
},
|
||||||
"rimraf": {
|
"rimraf": {
|
||||||
"version": "2.6.3",
|
"version": "2.6.3",
|
||||||
"resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"glob": "^7.1.3"
|
"glob": "^7.1.3"
|
||||||
@ -823,44 +785,37 @@
|
|||||||
},
|
},
|
||||||
"safe-buffer": {
|
"safe-buffer": {
|
||||||
"version": "5.1.2",
|
"version": "5.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"safer-buffer": {
|
"safer-buffer": {
|
||||||
"version": "2.1.2",
|
"version": "2.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"sax": {
|
"sax": {
|
||||||
"version": "1.2.4",
|
"version": "1.2.4",
|
||||||
"resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"semver": {
|
"semver": {
|
||||||
"version": "5.7.0",
|
"version": "5.7.0",
|
||||||
"resolved": "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"set-blocking": {
|
"set-blocking": {
|
||||||
"version": "2.0.0",
|
"version": "2.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"signal-exit": {
|
"signal-exit": {
|
||||||
"version": "3.0.2",
|
"version": "3.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"string-width": {
|
"string-width": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"code-point-at": "^1.0.0",
|
"code-point-at": "^1.0.0",
|
||||||
@ -870,8 +825,7 @@
|
|||||||
},
|
},
|
||||||
"string_decoder": {
|
"string_decoder": {
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"safe-buffer": "~5.1.0"
|
"safe-buffer": "~5.1.0"
|
||||||
@ -879,8 +833,7 @@
|
|||||||
},
|
},
|
||||||
"strip-ansi": {
|
"strip-ansi": {
|
||||||
"version": "3.0.1",
|
"version": "3.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"ansi-regex": "^2.0.0"
|
"ansi-regex": "^2.0.0"
|
||||||
@ -888,14 +841,12 @@
|
|||||||
},
|
},
|
||||||
"strip-json-comments": {
|
"strip-json-comments": {
|
||||||
"version": "2.0.1",
|
"version": "2.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"tar": {
|
"tar": {
|
||||||
"version": "4.4.8",
|
"version": "4.4.8",
|
||||||
"resolved": "https://registry.npmjs.org/tar/-/tar-4.4.8.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-LzHF64s5chPQQS0IYBn9IN5h3i98c12bo4NCO7e0sGM2llXQ3p2FGC5sdENN4cTW48O915Sh+x+EXx7XW96xYQ==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"chownr": "^1.1.1",
|
"chownr": "^1.1.1",
|
||||||
@ -909,14 +860,12 @@
|
|||||||
},
|
},
|
||||||
"util-deprecate": {
|
"util-deprecate": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"wide-align": {
|
"wide-align": {
|
||||||
"version": "1.1.3",
|
"version": "1.1.3",
|
||||||
"resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==",
|
|
||||||
"optional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"string-width": "^1.0.2 || 2"
|
"string-width": "^1.0.2 || 2"
|
||||||
@ -924,14 +873,12 @@
|
|||||||
},
|
},
|
||||||
"wrappy": {
|
"wrappy": {
|
||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"yallist": {
|
"yallist": {
|
||||||
"version": "3.0.3",
|
"version": "3.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/yallist/-/yallist-3.0.3.tgz",
|
"bundled": true,
|
||||||
"integrity": "sha512-S+Zk8DEWE6oKpV+vI3qWkaK+jSbIK86pCwe2IF/xwIpQ8jEuxpw9NyaGjmp9+BoJv5FV2piqCDcoCtStppiq2A==",
|
|
||||||
"optional": true
|
"optional": true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1731,9 +1678,9 @@
|
|||||||
"integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg=="
|
"integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg=="
|
||||||
},
|
},
|
||||||
"rollup": {
|
"rollup": {
|
||||||
"version": "1.25.1",
|
"version": "1.25.2",
|
||||||
"resolved": "https://registry.npmjs.org/rollup/-/rollup-1.25.1.tgz",
|
"resolved": "https://registry.npmjs.org/rollup/-/rollup-1.25.2.tgz",
|
||||||
"integrity": "sha512-K8ytdEzMa6anHSnfTIs2BLB+NXlQ4qmWwdNHBpYQNWCbZAzj+DRVk7+ssbLSgddwpFW1nThr2GElR+jASF2NPA==",
|
"integrity": "sha512-+7z6Wab/L45QCPcfpuTZKwKiB0tynj05s/+s2U3F2Bi7rOLPr9UcjUwO7/xpjlPNXA/hwnth6jBExFRGyf3tMg==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"@types/estree": "*",
|
"@types/estree": "*",
|
||||||
"@types/node": "*",
|
"@types/node": "*",
|
||||||
@ -2072,6 +2019,14 @@
|
|||||||
"version": "1.0.2",
|
"version": "1.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
|
"resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
|
||||||
"integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8="
|
"integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8="
|
||||||
|
},
|
||||||
|
"ws": {
|
||||||
|
"version": "7.2.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/ws/-/ws-7.2.0.tgz",
|
||||||
|
"integrity": "sha512-+SqNqFbwTm/0DC18KYzIsMTnEWpLwJsiasW/O17la4iDRRIO9uaHbvKiAS3AHgTiuuWerK/brj4O6MYZkei9xg==",
|
||||||
|
"requires": {
|
||||||
|
"async-limiter": "^1.0.0"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
"name": "doric",
|
"name": "doric",
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"description": "The JS Framework of Doric",
|
"description": "The JS Framework of Doric",
|
||||||
"main": "build/index.js",
|
"main": "bundle/doric-vm.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test": "echo \"Error: no test specified\" && exit 1",
|
"test": "echo \"Error: no test specified\" && exit 1",
|
||||||
"build": "tsc -p .&& rollup -c",
|
"build": "tsc -p .&& rollup -c",
|
||||||
@ -20,11 +20,13 @@
|
|||||||
},
|
},
|
||||||
"homepage": "https://github.com/doric-pub/doric#readme",
|
"homepage": "https://github.com/doric-pub/doric#readme",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@types/ws": "^6.0.3",
|
||||||
"reflect-metadata": "^0.1.13",
|
"reflect-metadata": "^0.1.13",
|
||||||
"rollup": "^1.17.0",
|
"rollup": "^1.17.0",
|
||||||
"rollup-plugin-node-resolve": "^5.2.0",
|
"rollup-plugin-node-resolve": "^5.2.0",
|
||||||
"rollup-watch": "^4.3.1",
|
"rollup-watch": "^4.3.1",
|
||||||
"tslib": "^1.10.0",
|
"tslib": "^1.10.0",
|
||||||
"typescript": "^3.5.3"
|
"typescript": "^3.5.3",
|
||||||
|
"ws": "^7.2.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,4 +25,15 @@ export default [
|
|||||||
],
|
],
|
||||||
external: ['reflect-metadata']
|
external: ['reflect-metadata']
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
input: "build/index.debug.js",
|
||||||
|
output: {
|
||||||
|
format: "cjs",
|
||||||
|
file: "bundle/doric-vm.js",
|
||||||
|
},
|
||||||
|
plugins: [
|
||||||
|
resolve({ jsnext: true, main: true }),
|
||||||
|
],
|
||||||
|
external: ['ws']
|
||||||
|
},
|
||||||
]
|
]
|
@ -21,17 +21,17 @@ import "reflect-metadata"
|
|||||||
* ``` TypeScript
|
* ``` TypeScript
|
||||||
* // load script in global scope
|
* // load script in global scope
|
||||||
* Reflect.apply(
|
* Reflect.apply(
|
||||||
* function(hego,context,Entry,require){
|
* function(doric,context,Entry,require){
|
||||||
* //Script content
|
* //Script content
|
||||||
* REG()
|
* REG()
|
||||||
* },hego.jsObtainContext(id),[
|
* },doric.jsObtainContext(id),[
|
||||||
* undefined,
|
* undefined,
|
||||||
* hego.jsObtainContext(id),
|
* doric.jsObtainContext(id),
|
||||||
* hego.jsObtainEntry(id),
|
* doric.jsObtainEntry(id),
|
||||||
* hego.__require__,
|
* doric.__require__,
|
||||||
* ])
|
* ])
|
||||||
* // load module in global scope
|
* // load module in global scope
|
||||||
* Reflect.apply(hego.jsRegisterModule,this,[
|
* Reflect.apply(doric.jsRegisterModule,this,[
|
||||||
* moduleName,
|
* moduleName,
|
||||||
* Reflect.apply(function(__module){
|
* Reflect.apply(function(__module){
|
||||||
* (function(module,exports,require){
|
* (function(module,exports,require){
|
||||||
@ -255,8 +255,18 @@ let __timerId__ = 0
|
|||||||
|
|
||||||
const timerInfos: Map<number, { callback: () => void, context?: Context }> = new Map
|
const timerInfos: Map<number, { callback: () => void, context?: Context }> = new Map
|
||||||
|
|
||||||
|
const _setTimeout = global.setTimeout
|
||||||
|
|
||||||
global.setTimeout = (handler: Function, timeout?: number | undefined, ...args: any[]) => {
|
const _setInterval = global.setInterval
|
||||||
|
|
||||||
|
const _clearTimeout = global.clearTimeout
|
||||||
|
|
||||||
|
const _clearInterval = global.clearInterval
|
||||||
|
|
||||||
|
global.setTimeout = function (handler: Function, timeout?: number | undefined, ...args: any[]) {
|
||||||
|
if (global.nativeSetTimer === undefined) {
|
||||||
|
return Reflect.apply(_setTimeout, undefined, arguments)
|
||||||
|
}
|
||||||
const id = __timerId__++
|
const id = __timerId__++
|
||||||
timerInfos.set(id, {
|
timerInfos.set(id, {
|
||||||
callback: () => {
|
callback: () => {
|
||||||
@ -268,7 +278,10 @@ global.setTimeout = (handler: Function, timeout?: number | undefined, ...args: a
|
|||||||
nativeSetTimer(id, timeout || 0, false)
|
nativeSetTimer(id, timeout || 0, false)
|
||||||
return id
|
return id
|
||||||
}
|
}
|
||||||
global.setInterval = (handler: Function, timeout?: number | undefined, ...args: any[]) => {
|
global.setInterval = function (handler: Function, timeout?: number | undefined, ...args: any[]) {
|
||||||
|
if (global.nativeSetTimer === undefined) {
|
||||||
|
return Reflect.apply(_setInterval, undefined, arguments)
|
||||||
|
}
|
||||||
const id = __timerId__++
|
const id = __timerId__++
|
||||||
timerInfos.set(id, {
|
timerInfos.set(id, {
|
||||||
callback: () => {
|
callback: () => {
|
||||||
@ -280,12 +293,18 @@ global.setInterval = (handler: Function, timeout?: number | undefined, ...args:
|
|||||||
return id
|
return id
|
||||||
}
|
}
|
||||||
|
|
||||||
global.clearTimeout = (timerId: number) => {
|
global.clearTimeout = function (timerId: number) {
|
||||||
|
if (global.nativeClearTimer === undefined) {
|
||||||
|
return Reflect.apply(_clearTimeout, undefined, arguments)
|
||||||
|
}
|
||||||
timerInfos.delete(timerId)
|
timerInfos.delete(timerId)
|
||||||
nativeClearTimer(timerId)
|
nativeClearTimer(timerId)
|
||||||
}
|
}
|
||||||
|
|
||||||
global.clearInterval = (timerId: number) => {
|
global.clearInterval = function (timerId: number) {
|
||||||
|
if (global.nativeClearTimer === undefined) {
|
||||||
|
return Reflect.apply(_clearInterval, undefined, arguments)
|
||||||
|
}
|
||||||
timerInfos.delete(timerId)
|
timerInfos.delete(timerId)
|
||||||
nativeClearTimer(timerId)
|
nativeClearTimer(timerId)
|
||||||
}
|
}
|
||||||
|
1
remote/.gitignore
vendored
1
remote/.gitignore
vendored
@ -1 +0,0 @@
|
|||||||
node_modules/
|
|
@ -1,20 +0,0 @@
|
|||||||
const WebSocket = require('ws')
|
|
||||||
const vm = require("vm")
|
|
||||||
|
|
||||||
const wss = new WebSocket.Server({ port: 2080 })
|
|
||||||
var sandbox = {}
|
|
||||||
var context = vm.createContext(sandbox)
|
|
||||||
|
|
||||||
wss.on('connection', function connection(ws) {
|
|
||||||
ws.on('message', function incoming(message) {
|
|
||||||
let messageObject = JSON.parse(message)
|
|
||||||
switch(messageObject.cmd) {
|
|
||||||
case "loadJS":
|
|
||||||
let result = vm.runInContext(messageObject.script, sandbox)
|
|
||||||
ws.send(JSON.stringify({cmd: 'loadJS', result: String(result)}))
|
|
||||||
break
|
|
||||||
case "evaluateJS":
|
|
||||||
break
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
|
21
remote/package-lock.json
generated
21
remote/package-lock.json
generated
@ -1,21 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "remote",
|
|
||||||
"version": "0.1.0",
|
|
||||||
"lockfileVersion": 1,
|
|
||||||
"requires": true,
|
|
||||||
"dependencies": {
|
|
||||||
"async-limiter": {
|
|
||||||
"version": "1.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz",
|
|
||||||
"integrity": "sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ=="
|
|
||||||
},
|
|
||||||
"ws": {
|
|
||||||
"version": "7.2.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/ws/-/ws-7.2.0.tgz",
|
|
||||||
"integrity": "sha512-+SqNqFbwTm/0DC18KYzIsMTnEWpLwJsiasW/O17la4iDRRIO9uaHbvKiAS3AHgTiuuWerK/brj4O6MYZkei9xg==",
|
|
||||||
"requires": {
|
|
||||||
"async-limiter": "^1.0.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,10 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "remote",
|
|
||||||
"version": "0.1.0",
|
|
||||||
"scripts": {
|
|
||||||
"test": "echo \"Error: no test specified\" && exit 1"
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"ws": "^7.2.0"
|
|
||||||
}
|
|
||||||
}
|
|
2
setup.sh
2
setup.sh
@ -8,4 +8,4 @@
|
|||||||
cd js-framework && npm install && npm run build && cd ..
|
cd js-framework && npm install && npm run build && cd ..
|
||||||
cd debugger && npm install && npm run build && cd ..
|
cd debugger && npm install && npm run build && cd ..
|
||||||
cd demo && npm install && npm run build && cd ..
|
cd demo && npm install && npm run build && cd ..
|
||||||
cd doric-cli && npm install && cd ..
|
cd doric-cli && npm install && npm link && cd ..
|
||||||
|
Reference in New Issue
Block a user