/ui - DOMException

My api is working just fine but for some reason, the /ui is not working.
I get a DOMException in the console:

Uncaught DOMException: Failed to set the ‘size’ property on ‘HTMLInputElement’: The value provided is 0, which is an invalid size.
at _e (http://localhost:62069/js/petite-vue.js?vfx=6.02:1:6985)
at L.fn (http://localhost:62069/js/petite-vue.js?vfx=6.02:1:6460)
at L.run (http://localhost:62069/js/petite-vue.js?vfx=6.02:1:2501)
at http://localhost:62069/js/petite-vue.js?vfx=6.02:1:14455
at effect (http://localhost:62069/js/petite-vue.js?vfx=6.02:1:14503)
at ye (http://localhost:62069/js/petite-vue.js?vfx=6.02:1:6368)
at Ye (http://localhost:62069/js/petite-vue.js?vfx=6.02:1:13937)
at Xe (http://localhost:62069/js/petite-vue.js?vfx=6.02:1:13871)
at Ue (http://localhost:62069/js/petite-vue.js?vfx=6.02:1:13175)
at new rt (http://localhost:62069/js/petite-vue.js?vfx=6.02:1:15383)

The Network calls look ok to me.

My AppHost has:

     Plugins.Add(new AuthFeature(() => new AuthUserSession(), 
                new IAuthProvider[] { new ApiKeyAuthProvider(AppSettings) { RequireSecureConnection = false }, new CredentialsAuthProvider(AppSettings) }));
            Plugins.Add(new RegistrationFeature());
            Plugins.Add(new AdminUsersFeature());

I am using SS6.0.2 (upgraded from 5), .Net 4.7.2 and running locally under IISExpress.
Using your .Net Framework Web Template, the /ui works fine.
I can’t figure what could be the difference. In my log, I am getting this warning

ServiceStack.Serialization.StringMapTypeDeserializer PID(12832) (11) [Warning] Property '"vfx"' does not exist on type '"ServiceStack.NativeTypes.TypesCommonJs"' 

Could it be related?

I don’t think that will be related. It is possible this issue has been fixed on our MyGet feed with 6.0.3, could you give that a go locally?

Working with the .NET template and not with your API likely means the /ui hasn’t handled something correctly related to your service metadata. Does it happen on every route for /ui? Eg if you navigate from /metadata and click on one of your services, do any of them load?

Could you check to make sure your app loads the /api/MetadataApp route correctly?

Hi Layoric,

I upgaded to 6.0.3 but no luck.
None of them load correctly when I navigate to the operations.
But the /api/metadata/app loads correctly.

@jbrabant are you able to share your /api/metadata/app response? This is the metadata that drives the UIs, I need to be able to reproduce the issue to try to resolve the problem.

There you go: https://pastebin.pl/view/bcb447d5

Do you have any custom JSON Serialization configured? If you do can you disable it to see if it’s causing the issue?

I removed the JsConfig and it works like a charm!!
The culprit is … (drum rolls) …

IncludeNullValues = true

Is a fix possible because I need it :slight_smile:

Thanks again for the awesome support!

Can you try with the latest v6.0.3 on MyGet by clearing your NuGet packages cache.

Works great! Thank you very much!

1 Like