Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
996cc8d
(docs)troubleshooting - add JS error
NansiYancheva Feb 22, 2024
1401491
My first signed commit!
NansiYancheva Mar 12, 2024
5b269d0
Update troubleshooting/js-errors.md
NansiYancheva Mar 20, 2024
a96f316
Update troubleshooting/js-errors.md
NansiYancheva Mar 20, 2024
1fa5f15
Update troubleshooting/js-errors.md
NansiYancheva Mar 20, 2024
c4094e9
Update troubleshooting/js-errors.md
NansiYancheva Mar 20, 2024
38e569c
Update troubleshooting/js-errors.md
NansiYancheva Mar 20, 2024
609a458
Update troubleshooting/js-errors.md
NansiYancheva Mar 20, 2024
511728f
updating docs article after review and adding a KB article
NansiYancheva Mar 21, 2024
6832148
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
14bd5ea
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
18b1d00
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
252e7a7
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
93028c3
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
16c448f
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
27ea5b7
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
26bf963
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
70b8b6d
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
a3cf6e1
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
0efd4f9
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
47e6d07
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
ed49117
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
c435afd
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
313490d
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
fd7af94
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
4c8bdf2
Update troubleshooting/js-errors.md
NansiYancheva Mar 22, 2024
3ce6600
Update knowledge-base/troubleshooting-js-errors-maximum-call.md
NansiYancheva Mar 22, 2024
46b1f38
updating after review
NansiYancheva Mar 22, 2024
e84a673
Update knowledge-base/common-maximum-call-stack-exceeded.md
NansiYancheva Mar 25, 2024
6169d58
Update knowledge-base/common-maximum-call-stack-exceeded.md
NansiYancheva Mar 25, 2024
e885a33
Update knowledge-base/common-maximum-call-stack-exceeded.md
NansiYancheva Mar 25, 2024
8064f48
Update knowledge-base/common-maximum-call-stack-exceeded.md
NansiYancheva Mar 25, 2024
4668738
Update knowledge-base/common-maximum-call-stack-exceeded.md
NansiYancheva Mar 25, 2024
8fe7be2
Update knowledge-base/common-maximum-call-stack-exceeded.md
NansiYancheva Mar 25, 2024
00da113
Update troubleshooting/js-errors.md
NansiYancheva Mar 25, 2024
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 70 additions & 0 deletions knowledge-base/common-maximum-call-stack-exceeded.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
---
title: JSException Maximum Call Stack Size Exceeded
description: Learn what causes the Maximum call stack size exceeded error and how to fix it.
type: troubleshooting
page_title: How to Fix JSException Maximum Call Stack Size Exceeded
slug: common-kb-maximum-call-stack-exceeded
tags: telerik, blazor, troubleshooting, javascript, js-error, exception
ticketid: 1641599, 1638959, 1639186, 1638288, 1642561, 1645266, 1641021
res_type: kb
---

## Environment

<table>
<tbody>
<tr>
<td>Product</td>
<td>UI for Blazor</td>
</tr>
</tbody>
</table>

## Description

This knowledge base article deals with the `Maximum call stack size exceeded` error.

## Error Message

>warning Microsoft.JSInterop.JSException: Maximum call stack size exceeded
>
> RangeError: Maximum call stack size exceeded

## Cause

The possible causes for the `Maximum call stack size exceeded` error are:

* Using an old version of Telerik UI for Blazor (4.5.0 and earlier) in .NET 8.
* Updating an existing app to .NET 8 without updating Telerik UI for Blazor.
* Using different versions of Telerik UI for Blazor in different projects in your solution. Some of the versions are earlier than 4.6.0.
* Building a .NET 6 Telerik Blazor app with the .NET 8 SDK on a Mac.
* Using a cached old version of `telerik-blazor.js` with up-to-date Telerik UI for Blazor version. In this case, the app may be runnable in one browser and not in another.

## Solution

To resolve the error:

* Use a Telerik UI for Blazor version, which is [compatible with .NET 8]({%slug system-requirements%}#supported-net-versions).
* Clear the browser cache.

Clearing the browser cache will reload the `telerik-blazor.js` file and the error should go away.

If the Telerik UI for Blazor version is up-to-date and the error persists, then clean the solution:

1. Close Visual Studio.
1. Delete all `bin` and `obj` folders in all projects in the solution.
1. Clear the browser cache.
1. Reopen Visual Studio and rebuild the app.


You can also add a cache buster to the `telerik-blazor.js` script, which will have a similar effect for the end users, as clearing their cache:

`<script src="_content/Telerik.UI.for.Blazor/js/telerik-blazor.js?version{{site.uiForBlazorLatestVersion}}"></script>`

## Notes

If you receive a `TelerikBlazor was undefined` JavaScript error after you clear the browser cache, then refer to the [documentation about `TelerikBlazor was undefined`]({%slug troubleshooting-js-errors%}#telerikblazor-was-undefined).

## See Also

* [JavaScript Errors]({%slug troubleshooting-js-errors%})
5 changes: 5 additions & 0 deletions troubleshooting/js-errors.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ This page provides solutions for JavaScript errors that you may encounter while
* [SyntaxError: Unexpected token](#syntaxerror-unexpected-token)
* [KeyNotFoundException: The given key `inputElementValue` was not present](#keynotfoundexception-the-given-key-inputelementvalue-was-not-present)
* [Object doesn't support property or method `assign`](#object-doesnt-support-property-or-method-assign)
* [Microsoft.JSInterop.JSException: Maximum call stack size exceeded](#maximum-call-stack-size-exceeded)

## TelerikBlazor was undefined

Expand Down Expand Up @@ -135,3 +136,7 @@ This error indicates that [the app is using an old or wrong version of the `tele
## Object doesn't support property or method 'assign'

Under IE, you may get errors similar to `Object doesn't support property or method 'assign'` or errors that relate other modern JS features that are not supported under IE. The reason is that we use modern code that may not work under IE - it is not one of the [browsers we support]({%slug system-requirements%}#browser-support), and WebAssembly does not work on it anyway, so modern Blazor apps won't run on IE regardless.

## Maximum call stack size exceeded

The error indicates that a [.NET 8 app is using a `telerik-blazor.js` file that is for version `4.5.0` or earlier]({%slug common-kb-maximum-call-stack-exceeded%}). If the Telerik UI for Blazor package version is up-to-date, a possible cause for the error is browser cache.