Open DreamDelerium opened 8 months ago
Thanks for reporting this, I will look into this, I have not noticed this with my prod deployments. Validating.
worse case, you could switch to a custom header CRSF protection, if this is a big problem.
Greetings Damien
Hello, I have developed my app using this template and it works fine running locally. But, when I run it on Azure I get this intermittent error:
blazor.webassembly.js:1 Exception: Microsoft.JSInterop.JSException: Could not find 'getAntiForgeryToken' ('getAntiForgeryToken' was undefined).
and this will be followed by a number of errors in my services (that rely on the token I assume). This error will resolve itself if I refresh the page but it does happen often. Is there a way to resolve this issue? I have Azure .Net set to 7 (as in my local environment) and I have tried turning WebSockets on.
My setup is a little different from how you setup your services. Here is an example:
Client/Services/MyService.cs:
private readonly IObjService _ObjService; public MyController(IObjService objService) { _objService = objService; } [HttpGet("get-all-objects")] public async Task<ActionResult<ServiceResponse<List>>> GetAllObjects()
{
return Ok(await this._objService.GetAllObjects(true)); }