ESP32 WebSocketsServer - stream pots output to web browser

I would like to stream pots data to a web browser using websockets. I'm using WebSocketsServer on a Huzzah but sendTXT isn't working, but does for Connected WStype. Is there a way to do this?

void loop() {

int potValue =analogRead(A4);

//Serial.println(potValue);

//delay(1000); //adding a delay slows connection times dramatically ;-(

webSocket.loop();

}

Doesn't anybody stream data to a client? How is it done with WebSocketsServer??