Summary: I embarked on a project based on the well-functioning ASP.NET Core example using SignalR and webpack. My objective is to incorporate this TypeScript library for client-side interpolation in a server-driven multiplayer game.
I suspect that the issue lies within webpack, as VisualStudio offers intellisense for the box2d.ts library, and tsc doesn't flag any errors when executed independently.
This endeavor marks my debut with TypeScript and webpack, so pardon any oversight on my part.
Error presented by webpack:
ERROR in ./src/index.ts
Module not found: Error: Can't resolve 'Box2D' in C:\Users\nathan.b\Desktop\Gamey\Gamey\src'
@ ./src/index.ts 2:0-31 3:14-26
UPDATE: Detailed error output:
(Error log details here)
...
index.ts:
Minimal code snippet to prevent compilation exclusion.
(TypeScript code here)
...
tsconfig.json:
{
"compilerOptions": {
"target": "es6",
"moduleResolution": "node",
"baseUrl": ".",
"paths": {
"Box2D": [ "./Box2D/Box2D" ]
}
}
}
webpack.config.js:
(Webpack configuration settings here)
...
Project layout: https://i.sstatic.net/EsFzV.png