ntcore-ts / @ntcore-ts/react / NtcoreProvider
Function: NtcoreProvider()
NtcoreProvider(
__namedParameters):Element
Defined in: react/src/lib/context.tsx:72
Provides a NetworkTables instance to the component tree. Must specify either team (robot team number) or uri (e.g. "localhost" or "roborio-973-frc.local"). Use useNtcore() in descendants to access the instance. Invalid port (NaN, non-integer, or outside 1–65535) throws so misconfiguration is caught early.
When using team, optional platform selects RoboRIO mDNS (default) or SystemCore 10.TE.AM.2.
Changing team, uri, port, or platform switches to the corresponding NetworkTables singleton. The previous instance is released (closed when no other provider still retains it).
Parameters
__namedParameters
Returns
Element