tjs-lang passed a couple of milestones over the last few days. It can already transpile itself, so it’s “self-hosted”. It can now transpile tosijs’s codebase and it can capture and re-emit ts declarations, while adding metadata to the tjs intermediate code to help anyone migrating from ts to tjs to replace complex generic types with simple predicates. Along the way tjs helped nail down a subtle and hard to replicate bug that has lingered for years. And then we decided to transpile a bunch of thorny libraries starting with Zod and ending with Effect.js (120k loc and truly perversely complex types). #javascript #typescript
Tonio Loewald’s Post
More Relevant Posts
-
Day 26/128 of my LeetCode journey 🚀 Today’s problem: Longest Substring Without Repeating Characters Solved it using the sliding window technique with a Set in JavaScript. This approach helped me optimize the solution to O(n) time complexity, making it efficient even for larger inputs. 💡 Key takeaway: Understanding how to dynamically adjust the window when duplicates appear is crucial for mastering string problems like this. Consistency is the real game-changer. Showing up every day, one problem at a time 💪 #LeetCode #128DaysOfCode #JavaScript #CodingJourney #DSA #ProblemSolving
To view or add a comment, sign in
-
-
🚀Day 2/200-Exploring Node.js Processes & Environment Variables Today I worked on understanding how parent and child processes behave in Node.js. 🔹 What I learned: A child process is a completely separate process, not a thread fork() creates a new Node process and runs the file automatically By default, environment variables are inherited from parent → child We can also inject custom env variables into the child process 🔹 Experiment: I created a custom variable (MY_VAR) that: ❌ Does not exist in the parent ✅ Exists only in the child process 🔹 Key Insight: Environment variables are process-specific, not global 🔹 Challenges I faced: Tried accessing process.env in the terminal (wrong context ❌) Confused between terminal vs Node runtime Debugging child process separately from parent 🔹 Solution: Used console.log and debugger inside child.js Understood the difference between system env vs process env 💡 This helped me clearly understand how Node.js handles processes internally. #NodeJS #BackendDevelopment #JavaScript #LearningInPublic #Debugging #WebDevelopment
To view or add a comment, sign in
-
-
Mastering the Node.js Event Loop is essential for anyone working with this technology. Understanding the Event Loop can be a game changer. The Event Loop is what makes Node.js non-blocking and highly scalable. It handles operations in several phases: - Timers: Executes setTimeout and setInterval - Pending Callbacks: Handles I/O callbacks - Idle/Prepare: For internal use - Poll: Fetches new I/O events - Check: Executes setImmediate - Close Callbacks: Manages cleanup operations A key insight to remember is that Node.js doesn’t run everything at once; it smartly queues tasks and executes them phase by phase, ensuring efficient performance. As a bonus tip, understanding the difference between setTimeout, setImmediate, and process.nextTick can significantly enhance your debugging and optimization skills. #NodeJS #JavaScript #BackendDevelopment #EventLoop #WebDevelopment #CodingTips
To view or add a comment, sign in
-
-
Published My New Blog on Hashnode! Understanding JavaScript can feel confusing at first—especially when it comes to Synchronous vs Asynchronous behavior. So I decided to break it down in the simplest way possible. 🧠 In this blog, I explained: What synchronous code really means (step-by-step execution) What asynchronous code is (doing things without waiting) Why JavaScript needs async behavior Real-life examples like API calls & timers Problems with blocking code (why apps freeze ) Easy diagrams to visualize everything link :- [https://lnkd.in/gkdRbW56] #JavaScript #WebDevelopment #CodingForBeginners #AsyncJavaScript #LearnToCode #FrontendDevelopment
To view or add a comment, sign in
-
-
🧠 Day 21 of 21days challenge Temporal Dead Zone (TDZ) in JavaScript ⚠️ Variables declared with let and const are hoisted… but cannot be accessed before initialization. This phase is called the Temporal Dead Zone. For easy understanding :- let/const are hoisted But not initialized immediately Access before init → ReferenceError 👉 That’s why accessing early breaks code This changed how I understand variable behavior 🚀 #JavaScript #TDZ #InterviewPrep #Frontend
To view or add a comment, sign in
-
-
Recently, taught Redux, a powerful JavaScript library used for global state management in modern applications. 💡 Key Concepts Covered: 1. Understanding what Redux is and why it is used 2. Core building blocks: Reducer, Action, and Initial State 3. How reducers process actions and update the state 4. How the store maintains and manages the global state 5. How the UI interacts using useSelector and useDispatch 🧠 Deep Dive Learnings: 1. Explained in detail what a reducer function is and how it works internally Introduced Redux Toolkit (@reduxjs/toolkit), where creating and configuring a slice automatically generates reducer logic 2. Understood how react-redux bindings provide hooks like useDispatch to dispatch actions and useSelector to access state Below is the diagram from the session conducted #Redux #ReactJS #JavaScript #StateManagement #WebDevelopment #Learning #CodingJourney #TechEducation
To view or add a comment, sign in
-
-
DAY 14 — The Dependency Array Is a Contract THE DEPENDENCY ARRAY IS A CONTRACT Lying to useEffect's dependency array is one of the most common React mistakes. The eslint-plugin-react-hooks rule exists for a reason. If you omit a variable from the deps array, your effect runs with a stale closure. If you include everything correctly, the effect re-runs when any dep changes. The temptation is to add [] to "run once" — but if your effect uses state or props, you're creating a silent bug. The real fix is to rethink the effect's structure, not silence the linter. Empty deps [] means "I swear this effect uses nothing from the component." If that's not true, you have a bug. How many times has the linter saved you from yourself? 👇 #useEffect #ReactHooks #BestPractices #JavaScript
To view or add a comment, sign in
-
-
👩💻 We built this in bootcamp with a professor walking us through it. I then decided to rebuild and upgrade it alone. The original was vanilla JavaScript + the OMDB API. It worked, but it was guided every step of the way. ⚙️ This time I upgraded it to React & TypeScript figuring out on the way what to change and why. ✨ Additional features that I added: – Favourites saved directly on the same page via localStorage – TypeScript to keep the data handling clean and intentional Turns out the best challenge after finishing a bootcamp is going back and doing it again, without a safety net. 🔗 Link: https://lnkd.in/eSXMHEKv #developerjourney #react #typescript #javascript
To view or add a comment, sign in
-
-
🚀 Day 963 of #1000DaysOfCode ✨ Difference Between var, let & const in JavaScript These three look similar… but behave very differently in real-world code. In today’s post, I’ve broken down the differences between `var`, `let`, and `const` in a simple and practical way, so you can understand when and why to use each of them. From scope and hoisting to re-declaration and mutability, these concepts directly impact how your code behaves — and are often the reason behind many unexpected bugs. I’ve also explained common mistakes developers make while using them, so you can avoid those pitfalls in your own projects. If you’re writing modern JavaScript, having clarity on this is absolutely essential. 👇 Which one do you use the most — `var`, `let`, or `const`? #Day963 #learningoftheday #1000daysofcodingchallenge #FrontendDevelopment #WebDevelopment #JavaScript #React #CodingCommunity #JSBasics
To view or add a comment, sign in
-
Ever wondered how JavaScript handles all those asynchronous tasks without freezing up? 🤔 It's all thanks to the magical event loop! This clever mechanism keeps things running smoothly behind the scenes. Think of it like a tireless waiter at a busy restaurant, constantly checking on your requests. ☕️ The call stack handles immediate tasks, while the callback queue waits for those async operations to finish. Then, the event loop zips them back into the call stack for processing! It's a beautiful dance that keeps your web pages interactive. 🕺💃 #JavaScript #EventLoop #WebDevelopment #Coding
To view or add a comment, sign in
-
More from this author
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development
If you want to play with it yourself it’s at platform.tosijs.net.