The markup compiler reports every problem with a stable id, at the line and column in the .html or .css file. A template that has any error still produces a stub class, so the only errors you see are the ones listed here.
| Id | Meaning | Fix |
|---|---|---|
| OUI0001 | A template has no class with its file name. | Declare public partial class Name for Name.html. |
| OUI0002 | Several classes match the template's name. | Put the template in the same folder as the class you mean. |
| OUI0003 | The class cannot be a markup component: not partial, generic, nested, static, or it derives from something other than Component. | Make it a top-level, non-generic partial class and drop the base. |
| OUI0004 | The template is not well formed: unclosed or mismatched tag, unterminated {, bad attribute. | Close the tag or brace; write {{ for a literal brace. |
| OUI0005 | A [State] or [Param] property cannot be generated: not partial, static, no setter, or more than 63. | [State] public partial int Count { get; set; }. |
| OUI0010 | Unknown element or component. | Use an HTML element, or a component class name starting with a capital letter. |
| OUI0011 | The element has no such attribute. | Fix the spelling; data-* and aria-* are always allowed. |
| OUI0012 | Unknown directive prefix. | The directives are on:, bind:, class: and style:. |
| OUI0013 | The element is not allowed in a component template (script, style, iframe, ...), or not allowed inside <svg> (SVG text, HTML elements, components, slots, animation, filters). | Use the class for behaviour and the .css file for styles; inside <svg> use the shapes listed in markup.md; put text in an HTML element beside the icon. |
| OUI0014 | An HTML event attribute such as onclick. | Use on:click="Handler". |
| OUI0015 | style="..." contains {...}. | Bind one property at a time: style:color="{expr}". |
| OUI0020 | Unknown DOM event in on:. | The message lists the events. |
| OUI0021 | The handler method does not exist. | Declare it, or write an expression in braces: on:click="{count++}". |
| OUI0022 | The handler must return void and take no parameter or the event payload type. | void M() or void M(MouseEvent e). |
| OUI0030 | A binding is not a valid C# expression. | Fix the expression. |
| OUI0031 | A binding names something that does not exist. | Declare the member in the class, or fix the name. |
| OUI0032 | A binding has the wrong type (a condition that is not bool, a parameter of another type). | Convert the value. |
| OUI0040 | bind: on an element that cannot be bound. | bind:value on input, textarea, select; bind:checked on checkbox and radio inputs. |
| OUI0041 | The bind: target cannot be assigned. | Bind a [State] property or a settable member. |
| OUI0050 | else or else-if without a preceding if. | Put it directly after the <template if> sibling. |
| OUI0051 | each is malformed or has no key. | <template each="{Items}" item="x" key="{x.Id}">. |
| OUI0052 | A control attribute is malformed (if without a condition, plain <template>, a slot template outside a component). | Give it a condition in braces. |
| OUI0060 | The component has no such parameter. | Mark the property [Param]. |
| OUI0061 | A required parameter is missing. | Pass it. |
| OUI0062 | A literal cannot become the parameter's type. | Use Name="{expr}". |
| OUI0063 | The component has no such slot. | Use a name from its <slot name="...">. |
| OUI0064 | Two referenced assemblies declare a component with this name, and the project declares none. | Rename one, or declare a component of that name in the project to choose it. |
| OUI0070 | ref is not ref="{Member}", or is on a component tag. | Bind an element: <input ref="{Search}" /> with ElementRef Search { get; } = new();. |
| OUI0100 | CSS syntax error. | Fix the declaration or rule. |
| OUI0101 | The CSS property is not supported by the renderer. | See docs/css-support.md; the message suggests the closest name. |
| OUI0102 | The value is not valid for the property. | The message lists the keywords. |
| OUI0103 | A CSS construct is not supported in a component stylesheet (@import, nested rules, unknown pseudo-classes). | Move it to the app's global styles. |
| OUI0110 | The compiler produced code that does not compile. This is a bug in the compiler. | Report it with the template. |