Comments (11)
Good point, although you are going to need to write Go
code eventually (unless you want to have a completely static app of course). If you only use the available widgets, you won't be able to get dynamic content.
I currently write widgets for termui that are kind of "higher level widgets" and only fulfill one task. The first widget is going to be a Hacker News newsfeed (that includes the top stories as well as the most recent ones). Later I will write widget that pulls my server's load (and CPU usage, memory, etc) using new relic. They have a pretty straightforward API and connecting your server to their service is free and super easy (it only took me a minute)*.
Right now, implementing that is kind of pointless, though. The only advantage is cleaner code but that's it.
*
just make sure you add the server to their Server monitoring Service and not the application service (because the usage is very limited if you don't pay).
from termui.
Hi @slezica, it's a good idea! Reminds me of graphite-web. I think this can be done by wrapping it up as a command line tool which continuously fetches data from an URI (*.json maybe). But as @Matt3o12 said, you may need some go codes if you want adding in custom logic.
Actually I've came across a similiar idea when implementing grid layout, thought a html-like tamplate would be helpful to define layout. Now this seems doable!
from termui.
Yeah, what you're describing sounds more like a project that someone should make using this as a rendering background, rather than having the library itself focus on making "html-like" directly.
from termui.
👍
from termui.
+1 for plain text configuration, and for polling JSON files or URL to ingest data. Termui is great but we can't write custom go
code.
Another idea for data sources: add an adapter to InfluxDB. All of our stats are stored in InfluxDB, but we don't have any way to display on the terminal.
To display InfluxDB stats on the browser we use Grafana - might be an interesting comparable for termui.
I agree with the OP - termui is a surprising and awesome tool. I think you are very close to having a tool that will attract a huge audience.
from termui.
Another idea that would make things a bit more dynamic would be to expose a JS api through something like otto, but I'm relatively new to termui to know if that would be doable or not 😁
from termui.
@fgrehm If you want a JS API, why not just go with blessed-contrib which is node-based?
from termui.
Just open a new repo termuid in response;)
from termui.
Yes, this looks really neat, but all I want to do is pipe some data to a widget and have it displayed. It seems like a widget should be able to accept a plain number, CSV, JSON, etc.
And to be sure this isn't already possible and I wasn't missing something, I had to come find this issue... :)
from termui.
I just came across https://github.com/yaronn/wopr which might be used as an inspiration
from termui.
A plain text configuration is a cool idea, but it's somewhat out of the scope of termui (I think). As was mentioned, you can create a higher level widget that reads its data from a file. But the widget design itself has to be in Go.
I realize this is an older issue, but just doing some housekeeping. 😺
from termui.
Related Issues (20)
- Broken link in wiki
- Is termui still actively maintained? HOT 12
- how does the line plot show the negative numbers HOT 1
- ModifierReverse causes characters to become clear in Gauge HOT 1
- enhancement: widget list support colored item HOT 1
- Colored Tables HOT 1
- Can't get better ascii border to display only the simple +,-,| ones. HOT 2
- How to use `[` and `]` characters in cells ? HOT 2
- Is it possible to set the size of an image widget inside a grid cell?
- [Request] add GIF image to describe each post in wiki.
- Issue after termbox-go is upgraded
- Grid cannot be aligned
- wishlist: support 'Symbols for Legacy Computing' 'Smooth mosaic terminal graphic characters' for graphs
- Feature Request: add containers for widgets
- termbox-go v1.1.1 incompatibility issues and wide character related issues HOT 3
- A example of autoscrolling for line wrapping scene
- List widget panics with `index out of range[-1]`
- The List.go demonstration shows an exception
- Is there any way to render charts without handing over the entire terminal?
- Error: no required module provides package github.com/gizak/termui/v3 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from termui.