Paul Krill
Editor at Large

New NPM will simplify React JavaScript development

news
Mar 14, 20162 mins

The Enclave module is currently being developed to provide a 'sane' API that's less reliant on Webpack

easy button
Credit: Thinkstock

The Enclave NPM module currently under development will offer smoother project setup in Facebook’s React JavaScript UI library.

Enclave provides an NPM for compiling JSX and ECMAScript 2015 code into “browser-ready” JavaScript. It takes developers through a series of prompts, creating an enclave.js file in an application’s root that will be used by Enclave to reference a build.

The project arose out of what its developer describes as complexity in configuring React applications with Webpack and Babel, and the experience with compile-to-JavaScript applications like Elm and CoffeeScript.

“I developed Enclave because after a year of doing React professionally, I still wasn’t comfortable setting up a new project,” developer Ean Platter, a software engineer at TechnologyAdvice, said. “It was tedious and frankly just not worth the effort. A lot of Web developers aren’t used to having to worry about compiling their code, they just drop in a CDN and it’s ready to go.”

The eventual goal with Enclave is to maintain a “sane” API that’s less reliant on Webpack. “All in all, this is open experimentation. Hopefully if you’re wanting to get started with React you’ll find Enclave is a helpful tool to get you up and running quickly,” the project’s GitHub page states.

TechnologyAdvice, which builds SaaS products and uses React for front-end development, started building Enclave within the past two weeks. “Just as Enclave is to help give people frictionless entry into building React applications, we want the contributing process to be as frictionless, especially for folks wanting to get into open source,” Platter said. As such, he wants to keep Enclave’s code and its API as unambiguous as possible, but more structure is needed. “There’s a lot of low-hanging fruit for developers interested in contributing.”

Despite the difficulties, Platter remains a fan of React. “The biggest thing that keeps me tied to React is the fact that it’s not HTML-centric. You’re writing JSX (HTML-like markup) in your .js files, which means you can pretty much do anything.”

Paul Krill

Paul Krill is editor at large at InfoWorld. Paul has been covering computer technology as a news and feature reporter for more than 35 years, including 30 years at InfoWorld. He has specialized in coverage of software development tools and technologies since the 1990s, and he continues to lead InfoWorld’s news coverage of software development platforms including Java and .NET and programming languages including JavaScript, TypeScript, PHP, Python, Ruby, Rust, and Go. Long trusted as a reporter who prioritizes accuracy, integrity, and the best interests of readers, Paul is sought out by technology companies and industry organizations who want to reach InfoWorld’s audience of software developers and other information technology professionals. Paul has won a “Best Technology News Coverage” award from IDG.

More from this author