# `MishkaCmsCore.Runtime.Resources.Validations.PageStateNames`
[🔗](https://github.com/mishka-group/mishka_cms_core/blob/v0.0.1/lib/mishka_cms_core/runtime/resources/__validations/page_state_names.ex#L5)

Refuses a page whose `state` names an assign it may not have.

Each name becomes an atom when the page compiles and an assign when it is mounted, so it is
checked here, at the action boundary every writer passes — the builder, the page form, the JSON
API and a seed alike:

  * it reads as an assign: `^[a-z_][a-zA-Z0-9_]*$`, and not `__`-prefixed;
  * it is not one the runtime or LiveView already owns — `@page`, `@flash`, `@csp_nonce` and the
    rest of `MishkaCmsCore.Runtime.PageState.reserved/0` — because assigning over one would break
    the page or the runtime around it;
  * it appears once, because the second value would silently replace the first.

The code beside each name is `MishkaCmsCore.Runtime.Resources.Validations.PageCodeCompiles`'s.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
