diff --git a/src/Microsoft.AspNetCore.Blazor.Browser.JS/src/Services/UriHelper.ts b/src/Microsoft.AspNetCore.Blazor.Browser.JS/src/Services/UriHelper.ts index 4499cddb31..33aa901f88 100644 --- a/src/Microsoft.AspNetCore.Blazor.Browser.JS/src/Services/UriHelper.ts +++ b/src/Microsoft.AspNetCore.Blazor.Browser.JS/src/Services/UriHelper.ts @@ -11,7 +11,7 @@ registerFunction(`${registeredFunctionPrefix}.getLocationHref`, registerFunction(`${registeredFunctionPrefix}.getBaseURI`, () => document.baseURI ? platform.toDotNetString(document.baseURI) : null); -registerFunction(`${registeredFunctionPrefix}.enableNavigationInteception`, () => { +registerFunction(`${registeredFunctionPrefix}.enableNavigationInterception`, () => { if (hasRegisteredEventListeners) { return; } diff --git a/src/Microsoft.AspNetCore.Blazor.Browser/Services/BrowserUriHelper.cs b/src/Microsoft.AspNetCore.Blazor.Browser/Services/BrowserUriHelper.cs index eb9972d09e..43241b86db 100644 --- a/src/Microsoft.AspNetCore.Blazor.Browser/Services/BrowserUriHelper.cs +++ b/src/Microsoft.AspNetCore.Blazor.Browser/Services/BrowserUriHelper.cs @@ -30,12 +30,12 @@ namespace Microsoft.AspNetCore.Blazor.Browser.Services { add { - EnsureNavigationInteceptionEnabled(); + EnsureNavigationInterceptionEnabled(); _onLocationChanged += value; } remove { - // We could consider deactivating the JS-side enableNavigationInteception + // We could consider deactivating the JS-side enableNavigationInterception // if there are no remaining listeners, but we don't need that currently. // If we ever do that, will also need to change the logic inside GetAbsoluteUri // so it knows not to continue using the cached URI. @@ -133,16 +133,16 @@ namespace Microsoft.AspNetCore.Blazor.Browser.Services _onLocationChanged?.Invoke(null, newAbsoluteUri); } - private static void EnsureNavigationInteceptionEnabled() + private static void EnsureNavigationInterceptionEnabled() { // Don't need thread safety because: // (1) there's only one UI thread - // (2) doesn't matter if we call enableNavigationInteception more than once anyway + // (2) doesn't matter if we call enableNavigationInterception more than once anyway if (!_hasEnabledNavigationInterception) { _hasEnabledNavigationInterception = true; RegisteredFunction.InvokeUnmarshalled( - $"{_functionPrefix}.enableNavigationInteception"); + $"{_functionPrefix}.enableNavigationInterception"); } } diff --git a/src/Microsoft.AspNetCore.Blazor/Json/SimpleJson/SimpleJson.cs b/src/Microsoft.AspNetCore.Blazor/Json/SimpleJson/SimpleJson.cs index 01075b22e8..f30d3104d9 100644 --- a/src/Microsoft.AspNetCore.Blazor/Json/SimpleJson/SimpleJson.cs +++ b/src/Microsoft.AspNetCore.Blazor/Json/SimpleJson/SimpleJson.cs @@ -554,7 +554,7 @@ namespace SimpleJson /// The object. /// /// - /// Returns true if successfull otherwise false. + /// Returns true if successful otherwise false. /// [SuppressMessage("Microsoft.Design", "CA1007:UseGenericsWhereAppropriate", Justification="Need to support .NET 2")] public static bool TryDeserializeObject(string json, out object obj) @@ -1260,7 +1260,7 @@ namespace SimpleJson public PocoJsonSerializerStrategy() { - ConstructorCache = new ReflectionUtils.ThreadSafeDictionary(ContructorDelegateFactory); + ConstructorCache = new ReflectionUtils.ThreadSafeDictionary(ConstructorDelegateFactory); GetCache = new ReflectionUtils.ThreadSafeDictionary>(GetterValueFactory); SetCache = new ReflectionUtils.ThreadSafeDictionary>>(SetterValueFactory); } @@ -1270,11 +1270,11 @@ namespace SimpleJson return clrPropertyName; } - internal virtual ReflectionUtils.ConstructorDelegate ContructorDelegateFactory(Type key) + internal virtual ReflectionUtils.ConstructorDelegate ConstructorDelegateFactory(Type key) { // We need List(int) constructor so that DeserializeObject method will work for generating IList-declared values var needsCapacityArgument = key.IsArray || key.IsConstructedGenericType && key.GetGenericTypeDefinition() == typeof(List<>); - return ReflectionUtils.GetContructor(key, needsCapacityArgument ? ArrayConstructorParameterTypes : EmptyTypes); + return ReflectionUtils.GetConstructor(key, needsCapacityArgument ? ArrayConstructorParameterTypes : EmptyTypes); } internal virtual IDictionary GetterValueFactory(Type type) @@ -1456,7 +1456,7 @@ namespace SimpleJson foreach (object o in jsonObject) list[i++] = DeserializeObject(o, type.GetElementType()); } - else if (ReflectionUtils.IsTypeGenericeCollectionInterface(type) || ReflectionUtils.IsAssignableFrom(typeof(IList), type)) + else if (ReflectionUtils.IsTypeGenericCollectionInterface(type) || ReflectionUtils.IsAssignableFrom(typeof(IList), type)) { Type innerType = ReflectionUtils.GetGenericListElementType(type); list = (IList)(ConstructorCache[type] ?? ConstructorCache[typeof(List<>).MakeGenericType(innerType)])(jsonObject.Count); @@ -1694,7 +1694,7 @@ namespace SimpleJson return GetTypeInfo(type).IsGenericType; } - public static bool IsTypeGenericeCollectionInterface(Type type) + public static bool IsTypeGenericCollectionInterface(Type type) { if (!IsTypeGeneric(type)) return false; @@ -1821,7 +1821,7 @@ namespace SimpleJson #endif } - public static ConstructorDelegate GetContructor(ConstructorInfo constructorInfo) + public static ConstructorDelegate GetConstructor(ConstructorInfo constructorInfo) { #if SIMPLE_JSON_NO_LINQ_EXPRESSION return GetConstructorByReflection(constructorInfo); @@ -1830,7 +1830,7 @@ namespace SimpleJson #endif } - public static ConstructorDelegate GetContructor(Type type, params Type[] argsType) + public static ConstructorDelegate GetConstructor(Type type, params Type[] argsType) { #if SIMPLE_JSON_NO_LINQ_EXPRESSION return GetConstructorByReflection(type, argsType); diff --git a/src/Microsoft.AspNetCore.Blazor/Rendering/ComponentState.cs b/src/Microsoft.AspNetCore.Blazor/Rendering/ComponentState.cs index feaaf519d2..9f9b7e3e81 100644 --- a/src/Microsoft.AspNetCore.Blazor/Rendering/ComponentState.cs +++ b/src/Microsoft.AspNetCore.Blazor/Rendering/ComponentState.cs @@ -25,7 +25,7 @@ namespace Microsoft.AspNetCore.Blazor.Rendering /// Constructs an instance of . /// /// The with which the new instance should be associated. - /// The externally visible identifer for the . The identifier must be unique in the context of the . + /// The externally visible identifier for the . The identifier must be unique in the context of the . /// The whose state is being tracked. public ComponentState(Renderer renderer, int componentId, IComponent component) { diff --git a/src/Microsoft.AspNetCore.Blazor/Routing/RouteTable.cs b/src/Microsoft.AspNetCore.Blazor/Routing/RouteTable.cs index 2d982b3889..59ba18a1ff 100644 --- a/src/Microsoft.AspNetCore.Blazor/Routing/RouteTable.cs +++ b/src/Microsoft.AspNetCore.Blazor/Routing/RouteTable.cs @@ -50,7 +50,7 @@ namespace Microsoft.AspNetCore.Blazor.Routing /// /Route/With/{parameter} is more specific than /{multiple}/With/{parameters} /// /Product/{id:int} is more specific than /Product/{id} /// - /// Routes can be ambigous if: + /// Routes can be ambiguous if: /// They are composed of literals and those literals have the same values (case insensitive) /// They are composed of a mix of literals and parameters, in the same relative order and the /// literals have the same values. @@ -62,9 +62,9 @@ namespace Microsoft.AspNetCore.Blazor.Routing /// To calculate the precedence we sort the list of routes as follows: /// * Shorter routes go first. /// * A literal wins over a parameter in precedence. - /// * For literals with different values (case insenitive) we choose the lexical order + /// * For literals with different values (case insensitive) we choose the lexical order /// * For parameters with different numbers of constraints, the one with more wins - /// If we get to the end of the comparison routing we've detected an ambigous pair of routes. + /// If we get to the end of the comparison routing we've detected an ambiguous pair of routes. internal static int RouteComparison(RouteEntry x, RouteEntry y) { var xTemplate = x.Template;