You can find the bot project on my Github – slack-genos.
There is a node package called slack that extracts all the Slack API and create functions for each.
npm i -S slack
They don’t provide TypeScript definition files, but we can create on own file under
With that I created a structure to run the bot.
ts-node is a package that allows you to run TypeScript (
.ts) files without a build step.
You can run a TypeScript project with:
Imagine a large scale application, with a big database full of tables and columns. Now imagine that you will have to remove a column from one of the tables, how would you guarantee that removing that column will not cause issues on your application?
await knex('student').where('deleted', false);
await are keywords commonly used on C#. They allow you to perform async operations without the callback hell.
The “callback hell” happens when you perform multiple async operations. For each operation you need to send a callback, a function that will execute when the operation completes.
- How do I install?
- Does it work on Linux/Mac?
- Does my editor support it?
- Do I have to learn a whole new language? Like CoffeeScript, Dart…?
- Any big companies using it?
- Does it support React?
- Have you ever coded a real project with it?
- Yes and I actually kept it compatible with the architecture of other (js) projects in my company. One of the projects is scaling.
- How many bugs did you prevent?
- Over 9000… A lot and very recently I found a bug in production in a very big project that would never happen if it was coded in TypeScript.
- Do you still use babel?
- Not if I get to choose which version of node I will be using. For some old versions some polyfills are really good… TypeScript does not add polyfills, it does not change your code more than enough to support a few ES features. You can check it out for yourself on TypeScript playground, the playground targets ES3, so if you use arrow functions or async/await TypeScript will “alter” your code.
I’m never satisfied with bootstraps out there, so I’m always creating some simple ones. Well this one is a bit more complex than the other ones I’ve built because of the complexity of React and Redux.
Check it out at brunolm/ts-react-redux-startup
I recently started using Workflowy (it is free), which is a website where you can create lists and it allows you to use as a brain dump. If you want to check it out you can use this link to get extra items https://workflowy.com/invite/35df8d82.lnx
On my Knowledge List I added things about Redux, Babel, Webpack and everything else…
I wanted to create a project using TypeScript + Babel. I knew I would have to setup a few things.
I choose to use Webpack because it has some dev tools, auto-reload. And it is nice to use loaders. But I couldn’t find any minimal simple examples, so I decided to create one.
brunolm/typescript-babel-webpack is a project with just the essential, nothing else. Simple and clean.
You can see that in this project there is a
README.md where I tried to write all the steps I went through to create that setup and the issues I faced.