前端学堂 http://www.felearn.com
当前位置首页 > 通全栈 > WebGIS> 正文

对wordpres将核心功能从PHP迁移到NodeJS有什么看法

2021-04-23 19:35:25 暂无评论 WebGIS 迁移   wordpres   看法

貌似是个误传,wordpress将会全面兼容REST模式,从而使一些新的JS前端特性被充分利用,而不是用nodejs取代PHP。
下面是部分博客节录。

WordPress is not being rewritten in Node.js
Relax. WordPress is written in PHP, but the Calypso admin interface for WordPress is written with popular front end tools like React and Lodash.

This is part of a popular trend – use your server to just give us raw JSON data, and then build your application entirely in JavaScript to consume that JSON data. WordPress essentially becomes an API which you can pull and push data from. This decoupling of the view and the backend logic has let the developers of WordPress move much faster because they don’t have 12 years of PHP view logic dragging them down.

What about WordPress is Node.js?
So, why are we seeing tweets about Node.js? Well, almost all front-end tooling is built in Node.js. Calypso is built with popular node tools like WebPack, Babel, Jade, Uglify, Hot Loader, Marked and over 100 other modules.

This is how the front end space is evolving and frankly I’m glad to see WordPress start using them because its one space we don’t see a lot of people using these tools.

猜你喜欢