Thanks to all the responses yesterday, I was encouraged to create my own table component today.
I like that the trade-offs with using a component library vs. a pre-built component remains the same despite the context.
For example, in a startup let's say, using pre-built components and styling over them might be a way to go.
However, when a component must resemble the mock-up in its entirety, some pre-built components provide configuration at a cost of customization and cannot be used.
#ChatGPT goes such a long way. Between my own head and the responses that came from my ChatGPT prompts, here was what I was able to accomplish today in 5 hours:
- Edit/Finish/Sort buttons and a select all checkbox inside a control panel
- A checkbox column that only appears when edit mode is set to true
- Sort functionality for A-z and Z-a
- Conditional contentEditable cells depending on state
- Pagination (first page, prev page, next page, last page)
- Map over an API call I make within a useEffect through axios
Between the component file and accompanying CSS, today I banged out around 400 lines of code, which I have no problem understanding, but would admittedly have taken longer to write if I needed to draw it out from scratch.
Some people say you shouldn't use ChatGPT, though I still don't get why they would (assuming you're not just copy pasting and praying it works of course!!!!!!!!!! !).
I understand that coding makes you better at coding, but to me it's a trade-off. If I was going to speak to you in German or Arabic, I wouldn't get nearly as many thoughts across, because I only speak English.
Likewise, if I was going to recreate today's code in Java, it would take me all week or longer, because I only know JavaScript and some Python.
The thing I love about ChatGPT is that it allows me to speak in my native language and turn those ideas into JavaScript (or whatever else I need).
It isn't a god, it's a godsend. There are plenty of times it falls short or is downright incompetent and unreliable. That is when old-fashioned learning comes into play, and is not an issue, because if literally using AI cannot solve your problem, then well, isn't it encouraging that you have to rely on the ole noggin to get the job done?
Hello #React developers,
Curious - have you ever found yourself in a position where, instead of using a pre-made component (such as one from a component library like Material UI) where you wonder if it's easier to make it yourself?
I am finding some of these feature-rich data tables very hard to customize. I am wondering if I ought to just create it from scratch, but wasn't sure if that was as farfetched as it might sound.
Have you ever ran into this situation?
Formal Methods | Software Engineering | Software History
2wI've written about this! https://www.hillelwayne.com/post/problems-with-the-4doc-model/