• q7_215854
  • 1.3MB
  • zip
  • 0
  • VIP专享
  • 0
  • 2022-06-14 18:06
Web2py + Svelte演示 演示将后端与前端集成在一起。 要求 python 3.6+和 使用npm的nodejs 安装 Python:将此项目扔到您的web2py应用程序文件夹中 Svelte :(从views/svelte文件夹中)运行npm install和npm run dev (用于开发,实时构建)或npm run build (用于生产,手动构建) 道具/数据 您在控制器中返回的所有数据都将作为“属性”传递到前端页面。 这意味着您可以将它们用作js变量。 例子: 如果在控制器中返回{'name': 'World', 'value': 15} ,则可以使用以下值: export let name ; // this will get the value World export let value ; // this will get the value 15 由
*Looking for a shareable component template? Go here --> [sveltejs/component-template](https://github.com/sveltejs/component-template)* --- # svelte app This is a project template for [Svelte](https://svelte.dev) apps. It lives at https://github.com/sveltejs/template. To create a new project based on this template using [degit](https://github.com/Rich-Harris/degit): ```bash npx degit sveltejs/template svelte-app cd svelte-app ``` *Note that you will need to have [Node.js](https://nodejs.org) installed.* ## Get started Install the dependencies... ```bash cd svelte-app npm install ``` ...then start [Rollup](https://rollupjs.org): ```bash npm run dev ``` Navigate to [localhost:5000](http://localhost:5000). You should see your app running. Edit a component file in `src`, save it, and reload the page to see your changes. By default, the server will only respond to requests from localhost. To allow connections from other computers, edit the `sirv` commands in package.json to include the option `--host`. ## Building and running in production mode To create an optimised version of the app: ```bash npm run build ``` You can run the newly built app with `npm run start`. This uses [sirv](https://github.com/lukeed/sirv), which is included in your package.json's `dependencies` so that the app will work when you deploy to platforms like [Heroku](https://heroku.com). ## Single-page app mode By default, sirv will only respond to requests that match files in `public`. This is to maximise compatibility with static fileservers, allowing you to deploy your app anywhere. If you're building a single-page app (SPA) with multiple routes, sirv needs to be able to respond to requests for *any* path. You can make it so by editing the `"start"` command in package.json: ```js "start": "sirv public --single" ``` ## Deploying to the web ### With [now](https://zeit.co/now) Install `now` if you haven't already: ```bash npm install -g now ``` Then, from within your project folder: ```bash cd public now deploy --name my-project ``` As an alternative, use the [Now desktop client](https://zeit.co/download) and simply drag the unzipped project folder to the taskbar icon. ### With [surge](https://surge.sh/) Install `surge` if you haven't already: ```bash npm install -g surge ``` Then, from within your project folder: ```bash npm run build surge public my-project.surge.sh ```
    • BKD:后端
      k 项目设置 npm install 编译和热重装以进行开发 npm run serve 编译并最小化生产 npm run build 整理和修复文件 npm run lint 自定义配置 请参阅。
    • Backend-template:后端模板
      backend_react_template npm安装 npm开始
    • 后端
      后端 설치&실행 설치:npm安装 생성이블생성:序列化db:create 실행:nodemon应用 DB테이블 1.用户(사용자정보테이블) userName:사용자이용자 userEmail:사용자이용자 userPassword:사용자 investType...
    • memebattle_backend:Memebattle后端
      Memebattle后端 构建设置 # install dependencies npm install # copy .env_s to .env and replace existed variables whith your # install pg-migrate npm install -g pg-migrate # use pg-migrate for migrate ...
    • Innoreva后端
      Innoreva后端 此回购用于后端代码。 npm安装 to install node modules npm开始 to start npm server
    • Avanzo后端
      Avanzo后端 安装模块快递 npm安装快递
    • 后端作业:作业板API
      Jobly API 设置 克隆仓库,然后运行npm install 。 移居 运行以下命令以运行启动迁移。 adonis migration: run 发展 运行以下命令为应用开发服务 adonis serve -- dev
    • estagio_nave:后端中殿
      后端中殿 安装 npm install 用法 npm start 作者 :bust_in_silhouette: 佩德罗·利尔(Pedro Leal) : LinkedIn) 表示支持 给一个 :star: 如果这个项目对您有帮助! 该自述文件是使用 :red_heart: 通过
    • 后端网页
      后端网页 项目设置 npm install 编译和热重装以进行开发 npm run serve 编译并最小化生产 npm run build 整理和修复文件 npm run lint 自定义配置 请参阅。
    • 在线学校测试后端
      在线学校测试后端 如何运行: 码头工人组成 我 npm运行typeorm迁移:运行 npm运行dev:server 楷模: 考试 问题 选项 功能: 创建考试,问题和选项 一项考试有很多问题,很多问题有很多选择 要创建问题,需要一个...