<Routes @rendermode="@InteractiveServer" /> in App.razor file makes Blazor Identity components such as Login, Register Not Found

未关闭
#1,214 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
35/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
停滞
技术栈
bootstrap, csharp

调研方向

Start by reproducing the reported authorization failure with .NET 9, BlazorBootstrap 3.5.0, and the supplied App.razor markup. Compare behavior with and without @rendermode on Routes; done means explaining whether BlazorBootstrap contributes to the failure and identifying a working setup for Identity routes.

由索引模型根据 Issue 内容生成。

描述

NOTE: We do not look at .zip attachments for issue investigation.

Describe the bug
Before scaffolding Blazor Identity, my Blazor Server App with Blazor.Bootstrap components works fine. After scaffolding Blazor Identity, authorization function totally doesn't work although @attribute [Authorize] was added.

It took a while to figure out the root cause is <Routes @rendermode="@InteractiveServer" /> in App.razor file. After changed <Routes @rendermode="@InteractiveServer" /> to , authorization function starts working.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Versions (please complete the following information):

  • .NET Version: [.NET 9]
  • BlazorBootstrap: [3.5.0]
  • Blazor Server: [e.g. WebAssembly, Server]
  • Blazor Interactive Render Mode: [Auto]
  • Blazor Interactivity Location: [Per page/component]

Sample code

<ImportMap />
<HeadOutlet @rendermode="@InteractiveServer" />
<script src="_framework/blazor.web.js"></script> <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-ndDqU0Gzau9qJ1lfW4pNLlhNTkCfHzAVBReH9diLvGRem5+R9g2FzA8ZGN954O5Q" crossorigin="anonymous"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/4.0.1/chart.umd.js" integrity="sha512-gQhCDsnnnUfaRzD8k1L5llCCV6O9HN09zClIzzeJ8OJ9MpGmIlCxm+pdCkqTwqJ4JcjbojFr79rl2F1mzcoLMQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/chartjs-plugin-datalabels/2.2.0/chartjs-plugin-datalabels.min.js" integrity="sha512-JPcRR8yFa8mmCsfrw4TNte1ZvF1e3+1SdGMslZvmrzDYxS69J7J49vkFL8u6u8PlPJK+H3voElBtUCzaXj+6ig==" crossorigin="anonymous" referrerpolicy="no-referrer"></script> <script src="https://cdn.jsdelivr.net/npm/sortablejs@latest/Sortable.min.js"></script> <script src="_content/Blazor.Bootstrap/blazor.bootstrap.js"></script>

GitHub repo
GitHub repo with minimal code to reproduce the issue.

Desktop (please complete the following information):

  • OS: [Windows]
  • Browser [chrome]
  • Version [11]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

主要语言
HTML
星标
1.2k
派生
111
平均合并
4 分钟
30 天内合并 PR
55

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

vikramlearning/blazorbootstrap 的其他 Issue

查看 vikramlearning/blazorbootstrap 的全部 Issue

相似的 Issue

更多 Security Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。