我可以在github页面上托管我的React/redux(客户端和api服务器)项目吗? [英] Can I host my React/redux (client and api server) project on github pages?

查看:96
本文介绍了我可以在github页面上托管我的React/redux(客户端和api服务器)项目吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道我可以通过仅提供bundle.js和index.html将我的react/redux应用程序托管在github页面上,但是我还可以为后端托管一个名为username.github.io/api的api服务器吗?

I know I can host my react/redux app on github pages by just serving the bundle.js and index.html, but can I also host an api server for the backend that is say username.github.io/api?

服务器使用node.js/express,它们是单独的目录.

The server uses node.js/express and they are separate directories.

还可以将服务器存储库设为私有,并仍将其托管在/api上吗?

Also, can I make the server repository private and still host it on /api?

我仔细阅读了github页面上有关创建项目"的文档,但这对我没有多大帮助.

I looked through the documentation on github pages about creating "projects" but it doesn't make much since to me.

如果任何人都可以对此有所了解,那么我们将不胜感激.

If anyone can shed some light on this, it would be must appreciated.

推荐答案

我建议您在 github 上运行 前端 代码em> ,同时具有外部托管的api,例如 AWS 或google cloud.

I suggest you run your front-end code on github while having an externally hosted api on say, AWS or google cloud.

Amazon和Google均提供免费软件包以进行小规模操作!

Amazon and google both provide free packages for small scale operations!

这样,您可以让github页面从 AWS 或Google云请求数据!

This way you can have your github page request data from AWS or google cloud!

这篇关于我可以在github页面上托管我的React/redux(客户端和api服务器)项目吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆