dotnet / dotnet/aspnetcore

@microsoft SignalR 8.0.9. Failed to resolve module specifier "module". Relative references must start with either "/", "./", or "../"

Open
#57,145 13 comments 1 reaction 0 assignees View on GitHub
area-signalr
Dominant language
C#
Stars
38.4k
Forks
10.9k
Avg merge
2d 10h
Merged PRs (30d)
281

Description

### Is there an existing issue for this?

- [X] I have searched the existing issues

### Describe the bug

Hey @BrennanConroy /Team

I have been following up on this issue. This issue was resolved in 8.0.0.

I am using Angular17 / Webpack and doing module federation by sharing signalr and so, I see this as first line in the bundled signalr module,

```
import { createRequire as __WEBPACK_EXTERNAL_createRequire } from "module";
```
When this file runs on browser, its thowing the error

**_Uncaught TypeError: Failed to resolve module specifier "module". Relative references must start with either "/", "./", or "../"._**

This is probably because of the below PR : [PR:5529](https://github.com/dotnet/aspnetcore/pull/55229) which reverted this [commit](https://github.com/dotnet/aspnetcore/commit/93520b67ad15b45b1fb39fe45fd97c06ebece7e7)

Can you please help me with a work around for this issue?

### Expected Behavior

This should not have node dynamic import releated code for angular broswer build.

### Steps To Reproduce

_No response_

### Exceptions (if any)

_No response_

### .NET Version

_No response_

### Anything else?

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.