Build against the local JSInterop (#22526)

This commit is contained in:
Pranav K 2020-06-09 14:38:13 -07:00 committed by GitHub
parent 4d367898b3
commit 758ca19edc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 24 additions and 12 deletions

View File

@ -12,6 +12,12 @@
</ItemGroup>
<ItemGroup>
<ProjectReference
Include="..\..\JSInterop\Microsoft.JSInterop.JS\src\Microsoft.JSInterop.JS.npmproj"
ReferenceOutputAssemblies="false"
SkipGetTargetFrameworkProperties="true"
UndefineProperties="TargetFramework"
Private="false" />
<ProjectReference
Include="..\..\SignalR\clients\ts\signalr\signalr.npmproj"
ReferenceOutputAssemblies="false"

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -16,7 +16,7 @@
"devDependencies": {
"@microsoft/signalr": "link:../../SignalR/clients/ts/signalr",
"@microsoft/signalr-protocol-msgpack": "link:../../SignalR/clients/ts/signalr-protocol-msgpack",
"@microsoft/dotnet-js-interop": "https://dotnet.myget.org/F/aspnetcore-dev/npm/@microsoft/dotnet-js-interop/-/@microsoft/dotnet-js-interop-5.0.0-alpha1.19572.2.tgz",
"@microsoft/dotnet-js-interop": "link:../../JSInterop/Microsoft.JSInterop.JS/src",
"@types/emscripten": "^1.39.3",
"@types/jest": "^24.9.1",
"@types/jsdom": "11.0.6",

View File

@ -1,4 +1,4 @@
import '@microsoft/dotnet-js-interop';
import { DotNet } from '@microsoft/dotnet-js-interop';
import './GlobalExports';
import * as signalR from '@microsoft/signalr';
import { MessagePackHubProtocol } from '@microsoft/signalr-protocol-msgpack';

View File

@ -1,4 +1,4 @@
import '@microsoft/dotnet-js-interop';
import { DotNet } from '@microsoft/dotnet-js-interop';
import './GlobalExports';
import * as Environment from './Environment';
import { monoPlatform } from './Platform/Mono/MonoPlatform';

View File

@ -1,3 +1,4 @@
import { DotNet } from '@microsoft/dotnet-js-interop';
import { attachDebuggerHotkey, hasDebuggingEnabled } from './MonoDebugger';
import { showErrorNotification } from '../../BootErrors';
import { WebAssemblyResourceLoader, LoadingResource } from '../WebAssemblyResourceLoader';

View File

@ -1,3 +1,5 @@
import { DotNet } from '@microsoft/dotnet-js-interop';
export function applyCaptureIdToElement(element: Element, referenceCaptureId: string) {
element.setAttribute(getCaptureIdAttributeName(referenceCaptureId), '');
}

View File

@ -345,9 +345,9 @@
"@types/istanbul-reports" "^1.1.1"
"@types/yargs" "^13.0.0"
"@microsoft/dotnet-js-interop@https://dotnet.myget.org/F/aspnetcore-dev/npm/@microsoft/dotnet-js-interop/-/@microsoft/dotnet-js-interop-5.0.0-alpha1.19572.2.tgz":
version "5.0.0-alpha1.19572.2"
resolved "https://dotnet.myget.org/F/aspnetcore-dev/npm/@microsoft/dotnet-js-interop/-/@microsoft/dotnet-js-interop-5.0.0-alpha1.19572.2.tgz#8abd8d315f2304ffa441d9fb42bd5a571969e9a0"
"@microsoft/dotnet-js-interop@link:../../JSInterop/Microsoft.JSInterop.JS/src":
version "0.0.0"
uid ""
"@microsoft/signalr-protocol-msgpack@link:../../SignalR/clients/ts/signalr-protocol-msgpack":
version "0.0.0"

View File

@ -0,0 +1,2 @@
node_modules/
dist/

View File

@ -5,6 +5,7 @@
"main": "dist/Microsoft.JSInterop.js",
"types": "dist/Microsoft.JSInterop.d.ts",
"scripts": {
"preclean": "yarn install",
"clean": "node node_modules/rimraf/bin.js ./dist",
"build": "npm run clean && npm run build:esm",
"build:lint": "node node_modules/tslint/bin/tslint -p ./tsconfig.json",

View File

@ -1,6 +1,6 @@
// This is a single-file self-contained module to avoid the need for a Webpack build
module DotNet {
export module DotNet {
(window as any).DotNet = DotNet; // Ensure reachable from anywhere
export type JsonReviver = ((key: any, value: any) => any);