# `PtcRunner.Kernel.Component`
[🔗](https://github.com/andreasronge/ptc_runner/blob/main/lib/ptc_runner/kernel/component.ex#L1)

A source-bearing, component-ID-addressed bundle input.

A component has one stable `id`, non-empty UTF-8 PTC-Lisp `source`, a sorted
duplicate-free list of component-ID `dependencies`, and a bounded `origin`
used for provenance and diagnostics. IDs match
`[a-z][a-z0-9._-]{0,127}`.

Components describe code and dependency identity only. They do not select
providers or grant runtime authority.

# `t`

```elixir
@type t() :: %PtcRunner.Kernel.Component{
  dependencies: [binary()],
  id: binary(),
  origin: binary(),
  source: binary()
}
```

# `new`

```elixir
@spec new(keyword()) :: {:ok, t()} | {:error, :invalid_component}
```

Validates and constructs a source component.

Options are `:id`, `:source`, optional `:dependencies`, and optional
`:origin`. Dependencies must already be sorted and unique. The default origin
is `"memory"`.

---

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