Skip to content

Commit 06531d3

Browse files
committed
Move Props to a different namespace
1 parent e5d3c25 commit 06531d3

File tree

5 files changed

+6
-4
lines changed

5 files changed

+6
-4
lines changed

InertiaCore/Inertia.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
using System.Runtime.CompilerServices;
2+
using InertiaCore.Props;
23
using InertiaCore.Utils;
34
using Microsoft.AspNetCore.Html;
45

InertiaCore/Utils/AlwaysProp.cs renamed to InertiaCore/Props/AlwaysProp.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
namespace InertiaCore.Utils;
1+
namespace InertiaCore.Props;
22

33
public class AlwaysProp
44
{

InertiaCore/Utils/LazyProp.cs renamed to InertiaCore/Props/LazyProp.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
namespace InertiaCore.Utils;
1+
namespace InertiaCore.Props;
22

33
public class LazyProp
44
{

InertiaCore/Response.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
using System.Text.Json.Serialization;
33
using InertiaCore.Extensions;
44
using InertiaCore.Models;
5+
using InertiaCore.Props;
56
using InertiaCore.Utils;
67
using Microsoft.AspNetCore.Mvc;
78
using Microsoft.AspNetCore.Mvc.ModelBinding;
@@ -155,7 +156,7 @@ public Response WithViewData(IDictionary<string, object> viewData)
155156
{
156157
var alwaysProps = _props.GetType().GetProperties()
157158
.Where(o => o.PropertyType == typeof(AlwaysProp))
158-
.ToDictionary(o => o.Name.ToCamelCase(), o => o.GetValue(_props)); ;
159+
.ToDictionary(o => o.Name.ToCamelCase(), o => o.GetValue(_props));
159160

160161
return props
161162
.Where(kv => kv.Value is not AlwaysProp)

InertiaCore/ResponseFactory.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
using System.Net;
22
using System.Text.Json;
33
using System.Text.Json.Serialization;
4-
using InertiaCore.Extensions;
54
using InertiaCore.Models;
5+
using InertiaCore.Props;
66
using InertiaCore.Ssr;
77
using InertiaCore.Utils;
88
using Microsoft.AspNetCore.Html;

0 commit comments

Comments
 (0)