Re: react nodes gulp running on apache offtopic!!
LinuxManMikeC <[email protected]>
| Newsgroups | gmane.comp.php.general |
|---|---|
| Message-ID | <CAG604KVKGJ_CL4T-Cxrn2GNYyFGg_xbargqiWY5bzwMj-rthvw@mail.gmail.com> |
Both repos are NPM projects. demo-website-oswaldos The NPM project is essentially used to manage the build tooling for this project. Otherwise, it's just standard front-end HTML and JavaScript. Note that they are using SASS which needs to be compiled to CSS. If you look at the "scripts" section of package.json, it contains predefined commands for the project including some build steps (npm run build). To run on Apache, just build the CSS, then host the static files on Apache. This is the most promising choice for incorporating a PHP back-end, as there isn't any back-end yet. Write back-end scripts in PHP and use the existing static HTML, or convert the static HTML to be generated by PHP. waitlist-landing-page This one is quite a bit more complex as it uses Next.js, a full-stack framework based on React components. As a full-stack framework, the back-end is dependent on a NodeJS runtime environment, where all the HTML is being generated from templates. They also chose to use TypeScript instead of JavaScript for this project. To run on Apache, just launch the NodeJS app (npm start) on your server and configure Apache as a reverse proxy to it. I wouldn't waste my time converting this to a PHP back-end. If I absolutely had to use this project as a starting point, I would rather spend my time learning Next.js, React, and TypeScript. On Sat, Jul 6, 2024 at 10:58 AM bruce <[email protected]> wrote: > > Hi. > > Thanks for the reply. > > The target apps -- github/repos are: > https://github.com/Filgeary/demo-website-oswaldos > --install no clue gulp???? > https://github.com/berat/waitlist-landing-page > --install no clue yarn??? > > I'd like to be able to get the apps running on Apache, but have no > clue how to accomplish this. > > I'd also like to be able to have the apps running as a php.javascript > app. This might entail redoing.converting the apps > > Thoughts/comments would be useful. > > Thanks > > > On Thu, Jul 4, 2024 at 5:34 PM LinuxManMikeC <[email protected]> wrote: > > > > Well, if they are NodeJS apps, they can't run as PHP apps. You can run them along side PHP by configuring how Apache handles different URL paths. Look into how to do a reverse proxy. > > > > If they're client side JavaScript, then you just drop the code into the webroot of the PHP app you want to integrate it with. > > > > Beyond that, we'd need to know what git repos you're trying to use, and what you're trying to do with them. > > > > > > On Thu, Jul 4, 2024, 13:38 bruce <[email protected]> wrote: > >> > >> hi. > >> > >> might be way off topic. > >> > >> found a couple of github apps. Appear to be gulp or react or nodes. The apps don't have install steps!. > >> > >> Trying to figure out how to install and run them on ubuntu/apache. > >> I'd actually like to have them run as test php apps on the server. > >> > >> Anyone have any pointers at all for this kind of issue. > >> > >> thanks!