I recently utilized the vue-property-decorator
to add a required prop to my component class. However, when I attempted to use the component without passing the prop, no console errors were displayed indicating that the required prop is missing. Why did this occur?
export default class Test extends Vue {
@Prop() private message!: string;
}
The following code executed without any errors:
<test message="Hello" />
In theory, the next code snippet should trigger an error but surprisingly it does not:
<test />