├── .editorconfig
├── .github
└── dependabot.yml
├── .gitignore
├── README.md
├── examples
├── angular-vite
│ ├── .gitignore
│ ├── README.md
│ ├── index.html
│ ├── package.json
│ ├── public
│ │ ├── angular.svg
│ │ └── vite.svg
│ ├── src
│ │ ├── app.component.ts
│ │ ├── main.ts
│ │ ├── style.css
│ │ └── vite-env.d.ts
│ ├── tsconfig.app.json
│ ├── tsconfig.json
│ └── vite.config.ts
├── basehref-examples
│ ├── README.md
│ ├── rspack-app
│ │ ├── .gitignore
│ │ ├── README.md
│ │ ├── index.html
│ │ ├── package.json
│ │ ├── rspack.config.ts
│ │ ├── src
│ │ │ ├── App.css
│ │ │ ├── App.tsx
│ │ │ ├── assets
│ │ │ │ └── react.svg
│ │ │ ├── index.css
│ │ │ ├── main.tsx
│ │ │ └── react-env.d.ts
│ │ └── tsconfig.json
│ ├── vite-app
│ │ ├── README.md
│ │ ├── index.html
│ │ ├── package.json
│ │ ├── public
│ │ │ └── .gitkeep
│ │ ├── src
│ │ │ ├── App.tsx
│ │ │ ├── index.css
│ │ │ └── main.tsx
│ │ ├── tsconfig.json
│ │ ├── tsconfig.node.json
│ │ └── vite.config.ts
│ └── webpack-app
│ │ ├── README.md
│ │ ├── package.json
│ │ ├── src
│ │ ├── App.tsx
│ │ ├── index.html
│ │ ├── index.tsx
│ │ └── styles.css
│ │ ├── tsconfig.json
│ │ └── webpack.config.js
├── create-default-webpack-mf
│ ├── README.md
│ ├── app1
│ │ ├── package.json
│ │ ├── public
│ │ │ └── index.html
│ │ ├── src
│ │ │ ├── App.js
│ │ │ ├── bootstrap.js
│ │ │ └── index.js
│ │ └── webpack.config.js
│ ├── app2
│ │ ├── package.json
│ │ ├── public
│ │ │ └── index.html
│ │ ├── src
│ │ │ ├── App.js
│ │ │ ├── bootstrap.js
│ │ │ └── index.js
│ │ └── webpack.config.js
│ └── package.json
├── create-mf-app-rspack
│ ├── .babelrc
│ ├── .gitignore
│ ├── package.json
│ ├── rspack.config.js
│ ├── src
│ │ ├── App.tsx
│ │ ├── index.css
│ │ ├── index.html
│ │ └── index.ts
│ └── tsconfig.json
├── create-nx-rspack-workspace-mf
│ ├── .editorconfig
│ ├── .eslintignore
│ ├── .eslintrc.json
│ ├── .gitignore
│ ├── .prettierignore
│ ├── .prettierrc
│ ├── README.md
│ ├── apps
│ │ ├── host-e2e
│ │ │ ├── .eslintrc.json
│ │ │ ├── cypress.config.ts
│ │ │ ├── project.json
│ │ │ ├── src
│ │ │ │ ├── e2e
│ │ │ │ │ └── app.cy.ts
│ │ │ │ ├── fixtures
│ │ │ │ │ └── example.json
│ │ │ │ └── support
│ │ │ │ │ ├── app.po.ts
│ │ │ │ │ ├── commands.ts
│ │ │ │ │ └── e2e.ts
│ │ │ └── tsconfig.json
│ │ ├── host
│ │ │ ├── .eslintrc.json
│ │ │ ├── jest.config.ts
│ │ │ ├── module-federation.config.ts
│ │ │ ├── package.json
│ │ │ ├── project.json
│ │ │ ├── rspack.config.prod.ts
│ │ │ ├── rspack.config.ts
│ │ │ ├── src
│ │ │ │ ├── app
│ │ │ │ │ ├── app.module.css
│ │ │ │ │ ├── app.spec.tsx
│ │ │ │ │ ├── app.tsx
│ │ │ │ │ └── nx-welcome.tsx
│ │ │ │ ├── assets
│ │ │ │ │ └── .gitkeep
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── favicon.ico
│ │ │ │ ├── index.html
│ │ │ │ ├── main.ts
│ │ │ │ └── styles.css
│ │ │ ├── tsconfig.app.json
│ │ │ ├── tsconfig.json
│ │ │ └── tsconfig.spec.json
│ │ ├── remote1-e2e
│ │ │ ├── .eslintrc.json
│ │ │ ├── cypress.config.ts
│ │ │ ├── project.json
│ │ │ ├── src
│ │ │ │ ├── e2e
│ │ │ │ │ └── app.cy.ts
│ │ │ │ ├── fixtures
│ │ │ │ │ └── example.json
│ │ │ │ └── support
│ │ │ │ │ ├── app.po.ts
│ │ │ │ │ ├── commands.ts
│ │ │ │ │ └── e2e.ts
│ │ │ └── tsconfig.json
│ │ ├── remote1
│ │ │ ├── .eslintrc.json
│ │ │ ├── jest.config.ts
│ │ │ ├── module-federation.config.ts
│ │ │ ├── package.json
│ │ │ ├── project.json
│ │ │ ├── rspack.config.prod.ts
│ │ │ ├── rspack.config.ts
│ │ │ ├── src
│ │ │ │ ├── app
│ │ │ │ │ ├── app.module.css
│ │ │ │ │ ├── app.spec.tsx
│ │ │ │ │ ├── app.tsx
│ │ │ │ │ └── nx-welcome.tsx
│ │ │ │ ├── assets
│ │ │ │ │ └── .gitkeep
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── favicon.ico
│ │ │ │ ├── index.html
│ │ │ │ ├── main.ts
│ │ │ │ ├── remote-entry.ts
│ │ │ │ └── styles.css
│ │ │ ├── tsconfig.app.json
│ │ │ ├── tsconfig.json
│ │ │ └── tsconfig.spec.json
│ │ ├── remote2-e2e
│ │ │ ├── .eslintrc.json
│ │ │ ├── cypress.config.ts
│ │ │ ├── project.json
│ │ │ ├── src
│ │ │ │ ├── e2e
│ │ │ │ │ └── app.cy.ts
│ │ │ │ ├── fixtures
│ │ │ │ │ └── example.json
│ │ │ │ └── support
│ │ │ │ │ ├── app.po.ts
│ │ │ │ │ ├── commands.ts
│ │ │ │ │ └── e2e.ts
│ │ │ └── tsconfig.json
│ │ └── remote2
│ │ │ ├── .eslintrc.json
│ │ │ ├── jest.config.ts
│ │ │ ├── module-federation.config.ts
│ │ │ ├── package.json
│ │ │ ├── project.json
│ │ │ ├── rspack.config.prod.ts
│ │ │ ├── rspack.config.ts
│ │ │ ├── src
│ │ │ ├── app
│ │ │ │ ├── app.module.css
│ │ │ │ ├── app.spec.tsx
│ │ │ │ ├── app.tsx
│ │ │ │ └── nx-welcome.tsx
│ │ │ ├── assets
│ │ │ │ └── .gitkeep
│ │ │ ├── bootstrap.tsx
│ │ │ ├── favicon.ico
│ │ │ ├── index.html
│ │ │ ├── main.ts
│ │ │ ├── remote-entry.ts
│ │ │ └── styles.css
│ │ │ ├── tsconfig.app.json
│ │ │ ├── tsconfig.json
│ │ │ └── tsconfig.spec.json
│ ├── jest.config.ts
│ ├── jest.preset.js
│ ├── nx.json
│ ├── package.json
│ └── tsconfig.base.json
├── create-nx-workspace-mf
│ ├── .editorconfig
│ ├── .eslintignore
│ ├── .eslintrc.json
│ ├── .gitignore
│ ├── .prettierignore
│ ├── .prettierrc
│ ├── .vscode
│ │ └── extensions.json
│ ├── README.md
│ ├── apps
│ │ ├── remote1
│ │ │ ├── .babelrc
│ │ │ ├── .eslintrc.json
│ │ │ ├── jest.config.ts
│ │ │ ├── module-federation.config.ts
│ │ │ ├── package.json
│ │ │ ├── project.json
│ │ │ ├── src
│ │ │ │ ├── app
│ │ │ │ │ ├── app.module.css
│ │ │ │ │ ├── app.spec.tsx
│ │ │ │ │ ├── app.tsx
│ │ │ │ │ └── nx-welcome.tsx
│ │ │ │ ├── assets
│ │ │ │ │ └── .gitkeep
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── favicon.ico
│ │ │ │ ├── index.html
│ │ │ │ ├── main.ts
│ │ │ │ ├── remote-entry.ts
│ │ │ │ └── styles.css
│ │ │ ├── tsconfig.app.json
│ │ │ ├── tsconfig.json
│ │ │ ├── tsconfig.spec.json
│ │ │ ├── webpack.config.prod.ts
│ │ │ └── webpack.config.ts
│ │ ├── remote2
│ │ │ ├── .babelrc
│ │ │ ├── .eslintrc.json
│ │ │ ├── jest.config.ts
│ │ │ ├── module-federation.config.ts
│ │ │ ├── package.json
│ │ │ ├── project.json
│ │ │ ├── src
│ │ │ │ ├── app
│ │ │ │ │ ├── app.module.css
│ │ │ │ │ ├── app.spec.tsx
│ │ │ │ │ ├── app.tsx
│ │ │ │ │ └── nx-welcome.tsx
│ │ │ │ ├── assets
│ │ │ │ │ └── .gitkeep
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── favicon.ico
│ │ │ │ ├── index.html
│ │ │ │ ├── main.ts
│ │ │ │ ├── remote-entry.ts
│ │ │ │ └── styles.css
│ │ │ ├── tsconfig.app.json
│ │ │ ├── tsconfig.json
│ │ │ ├── tsconfig.spec.json
│ │ │ ├── webpack.config.prod.ts
│ │ │ └── webpack.config.ts
│ │ └── shell
│ │ │ ├── .babelrc
│ │ │ ├── .eslintrc.json
│ │ │ ├── jest.config.ts
│ │ │ ├── module-federation.config.ts
│ │ │ ├── package.json
│ │ │ ├── project.json
│ │ │ ├── src
│ │ │ ├── app
│ │ │ │ ├── app.module.css
│ │ │ │ ├── app.spec.tsx
│ │ │ │ ├── app.tsx
│ │ │ │ └── nx-welcome.tsx
│ │ │ ├── assets
│ │ │ │ └── .gitkeep
│ │ │ ├── bootstrap.tsx
│ │ │ ├── favicon.ico
│ │ │ ├── index.html
│ │ │ ├── main.ts
│ │ │ └── styles.css
│ │ │ ├── tsconfig.app.json
│ │ │ ├── tsconfig.json
│ │ │ ├── tsconfig.spec.json
│ │ │ ├── webpack.config.prod.ts
│ │ │ └── webpack.config.ts
│ ├── jest.config.ts
│ ├── jest.preset.js
│ ├── nx.json
│ ├── package.json
│ └── tsconfig.base.json
├── modernjs-app
│ ├── README.md
│ ├── biome.json
│ ├── modern.config.ts
│ ├── package.json
│ ├── pnpm-lock.yaml
│ ├── src
│ │ ├── modern-app-env.d.ts
│ │ ├── modern.runtime.ts
│ │ └── routes
│ │ │ ├── index.css
│ │ │ ├── layout.tsx
│ │ │ └── page.tsx
│ └── tsconfig.json
├── nx-ng
│ ├── .eslintignore
│ ├── .eslintrc.json
│ ├── .gitignore
│ ├── .prettierignore
│ ├── .prettierrc
│ ├── .vscode
│ │ └── extensions.json
│ ├── README.md
│ ├── e2e
│ │ ├── .eslintrc.json
│ │ ├── cypress.config.ts
│ │ ├── project.json
│ │ ├── src
│ │ │ ├── e2e
│ │ │ │ └── app.cy.ts
│ │ │ ├── fixtures
│ │ │ │ └── example.json
│ │ │ └── support
│ │ │ │ ├── app.po.ts
│ │ │ │ ├── commands.ts
│ │ │ │ └── e2e.ts
│ │ └── tsconfig.json
│ ├── extra-webpack.config.js
│ ├── index-html-transform.js
│ ├── jest.config.ts
│ ├── jest.preset.js
│ ├── nx.json
│ ├── package.json
│ ├── project.json
│ ├── src
│ │ ├── app
│ │ │ ├── app.component.css
│ │ │ ├── app.component.html
│ │ │ ├── app.component.spec.ts
│ │ │ ├── app.component.ts
│ │ │ ├── app.config.ts
│ │ │ ├── app.routes.ts
│ │ │ └── nx-welcome.component.ts
│ │ ├── assets
│ │ │ └── .gitkeep
│ │ ├── favicon.ico
│ │ ├── index.html
│ │ ├── main.ts
│ │ ├── styles.css
│ │ └── test-setup.ts
│ ├── tsconfig.app.json
│ ├── tsconfig.editor.json
│ ├── tsconfig.json
│ └── tsconfig.spec.json
├── parcel-react
│ ├── .parcelrc
│ ├── index.html
│ ├── package.json
│ ├── src
│ │ ├── App.tsx
│ │ └── index.tsx
│ └── tsconfig.json
├── qwik-1.5
│ ├── .eslintignore
│ ├── .eslintrc.cjs
│ ├── .gitignore
│ ├── .prettierignore
│ ├── .vscode
│ │ ├── launch.json
│ │ ├── qwik-city.code-snippets
│ │ └── qwik.code-snippets
│ ├── README.md
│ ├── adapters
│ │ ├── netlify-edge
│ │ │ └── vite.config.ts
│ │ └── static
│ │ │ └── vite.config.ts
│ ├── netlify.toml
│ ├── package.json
│ ├── public
│ │ ├── _headers
│ │ ├── favicon.svg
│ │ ├── fonts
│ │ │ ├── poppins-400.woff2
│ │ │ ├── poppins-500.woff2
│ │ │ └── poppins-700.woff2
│ │ ├── manifest.json
│ │ └── robots.txt
│ ├── src
│ │ ├── components
│ │ │ ├── router-head
│ │ │ │ └── router-head.tsx
│ │ │ └── starter
│ │ │ │ ├── counter
│ │ │ │ ├── counter.module.css
│ │ │ │ └── counter.tsx
│ │ │ │ ├── footer
│ │ │ │ ├── footer.module.css
│ │ │ │ └── footer.tsx
│ │ │ │ ├── gauge
│ │ │ │ ├── gauge.module.css
│ │ │ │ └── index.tsx
│ │ │ │ ├── header
│ │ │ │ ├── header.module.css
│ │ │ │ └── header.tsx
│ │ │ │ ├── hero
│ │ │ │ ├── hero.module.css
│ │ │ │ └── hero.tsx
│ │ │ │ ├── icons
│ │ │ │ └── qwik.tsx
│ │ │ │ ├── infobox
│ │ │ │ ├── infobox.module.css
│ │ │ │ └── infobox.tsx
│ │ │ │ └── next-steps
│ │ │ │ ├── next-steps.module.css
│ │ │ │ └── next-steps.tsx
│ │ ├── entry.dev.tsx
│ │ ├── entry.netlify-edge.tsx
│ │ ├── entry.preview.tsx
│ │ ├── entry.ssr.tsx
│ │ ├── global.css
│ │ ├── media
│ │ │ └── thunder.png
│ │ ├── root.tsx
│ │ └── routes
│ │ │ ├── demo
│ │ │ ├── flower
│ │ │ │ ├── flower.css
│ │ │ │ └── index.tsx
│ │ │ └── todolist
│ │ │ │ ├── index.tsx
│ │ │ │ └── todolist.module.css
│ │ │ ├── index.tsx
│ │ │ ├── layout.tsx
│ │ │ ├── service-worker.ts
│ │ │ └── styles.css
│ ├── tsconfig.json
│ └── vite.config.ts
├── react-airbnb-clone
│ ├── .gitignore
│ ├── README.md
│ ├── apps
│ │ ├── categories
│ │ │ ├── .babelrc
│ │ │ ├── package.json
│ │ │ ├── postcss.config.js
│ │ │ ├── public
│ │ │ │ ├── assets
│ │ │ │ │ └── favicon.ico
│ │ │ │ ├── images
│ │ │ │ │ └── listing-placeholder.png
│ │ │ │ └── index.html
│ │ │ ├── src
│ │ │ │ ├── app.tsx
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── components
│ │ │ │ │ ├── Categories.tsx
│ │ │ │ │ ├── CategoryBox.tsx
│ │ │ │ │ └── Container.tsx
│ │ │ │ ├── expose.tsx
│ │ │ │ ├── globals.css
│ │ │ │ └── index.ts
│ │ │ ├── tailwind.config.js
│ │ │ ├── tsconfig.json
│ │ │ └── webpack.config.js
│ │ ├── favorites
│ │ │ ├── .babelrc
│ │ │ ├── package.json
│ │ │ ├── postcss.config.js
│ │ │ ├── public
│ │ │ │ ├── assets
│ │ │ │ │ └── favicon.ico
│ │ │ │ ├── images
│ │ │ │ │ └── listing-placeholder.png
│ │ │ │ └── index.html
│ │ │ ├── src
│ │ │ │ ├── app.tsx
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── common
│ │ │ │ │ ├── actions
│ │ │ │ │ │ ├── deleteFavorite.ts
│ │ │ │ │ │ ├── getCurrentUser.ts
│ │ │ │ │ │ ├── getFavoriteListings.ts
│ │ │ │ │ │ ├── getListings.ts
│ │ │ │ │ │ ├── mocks
│ │ │ │ │ │ │ └── index.ts
│ │ │ │ │ │ ├── saveFavorite.ts
│ │ │ │ │ │ └── saveUser.ts
│ │ │ │ │ ├── hooks
│ │ │ │ │ │ ├── useCountries.ts
│ │ │ │ │ │ ├── useCurrentUser.ts
│ │ │ │ │ │ ├── useFavorite.ts
│ │ │ │ │ │ └── useLoginModal.ts
│ │ │ │ │ ├── libs
│ │ │ │ │ │ ├── axios.ts
│ │ │ │ │ │ └── fetcher.ts
│ │ │ │ │ └── types
│ │ │ │ │ │ └── index.ts
│ │ │ │ ├── components
│ │ │ │ │ ├── Button.tsx
│ │ │ │ │ ├── Container.tsx
│ │ │ │ │ ├── Heading.tsx
│ │ │ │ │ ├── HeartButton.tsx
│ │ │ │ │ └── listings
│ │ │ │ │ │ └── ListingCard.tsx
│ │ │ │ ├── custom.d.ts
│ │ │ │ ├── expose.tsx
│ │ │ │ ├── favorites.tsx
│ │ │ │ ├── globals.css
│ │ │ │ └── index.ts
│ │ │ ├── tailwind.config.js
│ │ │ ├── tsconfig.json
│ │ │ └── webpack.config.js
│ │ ├── home
│ │ │ ├── .babelrc
│ │ │ ├── package.json
│ │ │ ├── postcss.config.js
│ │ │ ├── public
│ │ │ │ ├── assets
│ │ │ │ │ └── favicon.ico
│ │ │ │ ├── images
│ │ │ │ │ └── listing-placeholder.png
│ │ │ │ └── index.html
│ │ │ ├── src
│ │ │ │ ├── app.tsx
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── common
│ │ │ │ │ ├── actions
│ │ │ │ │ │ ├── deleteListings.ts
│ │ │ │ │ │ ├── getCurrentUser.ts
│ │ │ │ │ │ ├── getListings.ts
│ │ │ │ │ │ ├── mocks
│ │ │ │ │ │ │ └── index.ts
│ │ │ │ │ │ └── saveUser.ts
│ │ │ │ │ ├── hooks
│ │ │ │ │ │ ├── useCountries.ts
│ │ │ │ │ │ ├── useCurrentUser.ts
│ │ │ │ │ │ ├── useFavorite.ts
│ │ │ │ │ │ ├── useListings.ts
│ │ │ │ │ │ └── useLoginModal.ts
│ │ │ │ │ ├── libs
│ │ │ │ │ │ ├── axios.ts
│ │ │ │ │ │ └── fetcher.ts
│ │ │ │ │ └── types
│ │ │ │ │ │ └── index.ts
│ │ │ │ ├── components
│ │ │ │ │ ├── Button.tsx
│ │ │ │ │ ├── Container.tsx
│ │ │ │ │ ├── HeartButton.tsx
│ │ │ │ │ └── listings
│ │ │ │ │ │ └── ListingCard.tsx
│ │ │ │ ├── custom.d.ts
│ │ │ │ ├── expose.tsx
│ │ │ │ ├── globals.css
│ │ │ │ ├── home.tsx
│ │ │ │ └── index.ts
│ │ │ ├── tailwind.config.js
│ │ │ ├── tsconfig.json
│ │ │ └── webpack.config.js
│ │ ├── properties
│ │ │ ├── .babelrc
│ │ │ ├── package.json
│ │ │ ├── postcss.config.js
│ │ │ ├── public
│ │ │ │ ├── assets
│ │ │ │ │ └── favicon.ico
│ │ │ │ ├── images
│ │ │ │ │ └── listing-placeholder.png
│ │ │ │ └── index.html
│ │ │ ├── src
│ │ │ │ ├── app.tsx
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── common
│ │ │ │ │ ├── actions
│ │ │ │ │ │ ├── deleteListings.ts
│ │ │ │ │ │ ├── getCurrentUser.ts
│ │ │ │ │ │ ├── getListings.ts
│ │ │ │ │ │ ├── mocks
│ │ │ │ │ │ │ └── index.ts
│ │ │ │ │ │ └── saveUser.ts
│ │ │ │ │ ├── hooks
│ │ │ │ │ │ ├── useCountries.ts
│ │ │ │ │ │ ├── useCurrentUser.ts
│ │ │ │ │ │ ├── useFavorite.ts
│ │ │ │ │ │ ├── useListings.ts
│ │ │ │ │ │ └── useLoginModal.ts
│ │ │ │ │ ├── libs
│ │ │ │ │ │ ├── axios.ts
│ │ │ │ │ │ └── fetcher.ts
│ │ │ │ │ └── types
│ │ │ │ │ │ └── index.ts
│ │ │ │ ├── components
│ │ │ │ │ ├── Button.tsx
│ │ │ │ │ ├── Container.tsx
│ │ │ │ │ ├── Heading.tsx
│ │ │ │ │ ├── HeartButton.tsx
│ │ │ │ │ └── listings
│ │ │ │ │ │ └── ListingCard.tsx
│ │ │ │ ├── custom.d.ts
│ │ │ │ ├── expose.tsx
│ │ │ │ ├── globals.css
│ │ │ │ ├── index.ts
│ │ │ │ └── properties.tsx
│ │ │ ├── tailwind.config.js
│ │ │ ├── tsconfig.json
│ │ │ └── webpack.config.js
│ │ ├── react-host
│ │ │ ├── .babelrc
│ │ │ ├── federated.d.ts
│ │ │ ├── package.json
│ │ │ ├── postcss.config.js
│ │ │ ├── public
│ │ │ │ ├── assets
│ │ │ │ │ └── favicon.ico
│ │ │ │ ├── images
│ │ │ │ │ ├── listing-placeholder.png
│ │ │ │ │ ├── logo.png
│ │ │ │ │ └── placeholder.jpg
│ │ │ │ └── index.html
│ │ │ ├── src
│ │ │ │ ├── _error.tsx
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── common
│ │ │ │ │ ├── actions
│ │ │ │ │ │ ├── deleteFavorite.ts
│ │ │ │ │ │ ├── deleteListings.ts
│ │ │ │ │ │ ├── deleteReservation.ts
│ │ │ │ │ │ ├── getCurrentUser.ts
│ │ │ │ │ │ ├── getFavoriteListings.ts
│ │ │ │ │ │ ├── getListingById.ts
│ │ │ │ │ │ ├── getListings.ts
│ │ │ │ │ │ ├── getReservations.ts
│ │ │ │ │ │ ├── mocks
│ │ │ │ │ │ │ └── index.ts
│ │ │ │ │ │ ├── saveFavorite.ts
│ │ │ │ │ │ ├── saveListing.ts
│ │ │ │ │ │ ├── saveReservation.ts
│ │ │ │ │ │ └── saveUser.ts
│ │ │ │ │ ├── hooks
│ │ │ │ │ │ ├── useCountries.ts
│ │ │ │ │ │ ├── useCurrentUser.ts
│ │ │ │ │ │ ├── useFavorite.ts
│ │ │ │ │ │ ├── useFavorites.ts
│ │ │ │ │ │ ├── useListing.ts
│ │ │ │ │ │ ├── useListings.ts
│ │ │ │ │ │ ├── useLoginModal.ts
│ │ │ │ │ │ ├── useRegisterModal.ts
│ │ │ │ │ │ ├── useRentModal.ts
│ │ │ │ │ │ ├── useReservations.ts
│ │ │ │ │ │ ├── useSearchModal.ts
│ │ │ │ │ │ └── useShowRemotes.ts
│ │ │ │ │ ├── libs
│ │ │ │ │ │ ├── axios.ts
│ │ │ │ │ │ └── fetcher.ts
│ │ │ │ │ └── types
│ │ │ │ │ │ └── index.ts
│ │ │ │ ├── components
│ │ │ │ │ ├── Avatar.tsx
│ │ │ │ │ ├── Button.tsx
│ │ │ │ │ ├── Container.tsx
│ │ │ │ │ ├── EmptyState.tsx
│ │ │ │ │ ├── Heading.tsx
│ │ │ │ │ ├── HeartButton.tsx
│ │ │ │ │ ├── Loader.tsx
│ │ │ │ │ ├── Map.tsx
│ │ │ │ │ ├── RemoteWrap.tsx
│ │ │ │ │ ├── inputs
│ │ │ │ │ │ ├── Calendar.tsx
│ │ │ │ │ │ ├── CategoryInput.tsx
│ │ │ │ │ │ ├── Counter.tsx
│ │ │ │ │ │ ├── CountrySelect.tsx
│ │ │ │ │ │ ├── ImageUpload.tsx
│ │ │ │ │ │ ├── Input.tsx
│ │ │ │ │ │ └── calendar-styles.css
│ │ │ │ │ ├── listings
│ │ │ │ │ │ ├── ListingCard.tsx
│ │ │ │ │ │ ├── ListingCategory.tsx
│ │ │ │ │ │ ├── ListingHead.tsx
│ │ │ │ │ │ ├── ListingInfo.tsx
│ │ │ │ │ │ └── ListingReservation.tsx
│ │ │ │ │ ├── map-styles.css
│ │ │ │ │ ├── modals
│ │ │ │ │ │ ├── LoginModal.tsx
│ │ │ │ │ │ ├── Modal.tsx
│ │ │ │ │ │ ├── RegisterModal.tsx
│ │ │ │ │ │ ├── RentModal.tsx
│ │ │ │ │ │ └── SearchModal.tsx
│ │ │ │ │ └── navbar
│ │ │ │ │ │ ├── Logo.tsx
│ │ │ │ │ │ ├── MenuItem.tsx
│ │ │ │ │ │ ├── Navbar.tsx
│ │ │ │ │ │ ├── RemoteToggle.tsx
│ │ │ │ │ │ ├── Search.tsx
│ │ │ │ │ │ ├── UserMenu.tsx
│ │ │ │ │ │ └── categories.tsx
│ │ │ │ ├── custom.d.ts
│ │ │ │ ├── globals.css
│ │ │ │ ├── index.ts
│ │ │ │ ├── layout.tsx
│ │ │ │ ├── pages
│ │ │ │ │ ├── favorites
│ │ │ │ │ │ └── index.tsx
│ │ │ │ │ ├── home
│ │ │ │ │ │ └── index.tsx
│ │ │ │ │ ├── listings
│ │ │ │ │ │ └── index.tsx
│ │ │ │ │ ├── properties
│ │ │ │ │ │ └── index.tsx
│ │ │ │ │ ├── reservations
│ │ │ │ │ │ └── index.tsx
│ │ │ │ │ └── trips
│ │ │ │ │ │ └── index.tsx
│ │ │ │ ├── providers
│ │ │ │ │ ├── ModalsProvider.tsx
│ │ │ │ │ └── ToasterProvider.tsx
│ │ │ │ ├── routes.tsx
│ │ │ │ └── templates
│ │ │ │ │ └── ListingClient.tsx
│ │ │ ├── tailwind.config.js
│ │ │ ├── tsconfig.json
│ │ │ └── webpack.config.js
│ │ ├── reservations
│ │ │ ├── .babelrc
│ │ │ ├── package.json
│ │ │ ├── postcss.config.js
│ │ │ ├── public
│ │ │ │ ├── assets
│ │ │ │ │ └── favicon.ico
│ │ │ │ ├── images
│ │ │ │ │ └── listing-placeholder.png
│ │ │ │ └── index.html
│ │ │ ├── src
│ │ │ │ ├── app.tsx
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── common
│ │ │ │ │ ├── actions
│ │ │ │ │ │ ├── deleteListings.ts
│ │ │ │ │ │ ├── getCurrentUser.ts
│ │ │ │ │ │ ├── getListings.ts
│ │ │ │ │ │ ├── getReservations.ts
│ │ │ │ │ │ ├── mocks
│ │ │ │ │ │ │ └── index.ts
│ │ │ │ │ │ └── saveUser.ts
│ │ │ │ │ ├── hooks
│ │ │ │ │ │ ├── useCountries.ts
│ │ │ │ │ │ ├── useCurrentUser.ts
│ │ │ │ │ │ ├── useFavorite.ts
│ │ │ │ │ │ ├── useListings.ts
│ │ │ │ │ │ ├── useLoginModal.ts
│ │ │ │ │ │ └── useReservations.ts
│ │ │ │ │ ├── libs
│ │ │ │ │ │ ├── axios.ts
│ │ │ │ │ │ └── fetcher.ts
│ │ │ │ │ └── types
│ │ │ │ │ │ └── index.ts
│ │ │ │ ├── components
│ │ │ │ │ ├── Button.tsx
│ │ │ │ │ ├── Container.tsx
│ │ │ │ │ ├── Heading.tsx
│ │ │ │ │ ├── HeartButton.tsx
│ │ │ │ │ └── listings
│ │ │ │ │ │ └── ListingCard.tsx
│ │ │ │ ├── custom.d.ts
│ │ │ │ ├── expose.tsx
│ │ │ │ ├── globals.css
│ │ │ │ ├── index.ts
│ │ │ │ └── reservations.tsx
│ │ │ ├── tailwind.config.js
│ │ │ ├── tsconfig.json
│ │ │ └── webpack.config.js
│ │ └── trips
│ │ │ ├── .babelrc
│ │ │ ├── package.json
│ │ │ ├── postcss.config.js
│ │ │ ├── public
│ │ │ ├── assets
│ │ │ │ └── favicon.ico
│ │ │ ├── images
│ │ │ │ └── listing-placeholder.png
│ │ │ └── index.html
│ │ │ ├── src
│ │ │ ├── app.tsx
│ │ │ ├── bootstrap.tsx
│ │ │ ├── common
│ │ │ │ ├── actions
│ │ │ │ │ ├── deleteListings.ts
│ │ │ │ │ ├── getCurrentUser.ts
│ │ │ │ │ ├── getListings.ts
│ │ │ │ │ ├── getReservations.ts
│ │ │ │ │ ├── mocks
│ │ │ │ │ │ └── index.ts
│ │ │ │ │ └── saveUser.ts
│ │ │ │ ├── hooks
│ │ │ │ │ ├── useCountries.ts
│ │ │ │ │ ├── useCurrentUser.ts
│ │ │ │ │ ├── useFavorite.ts
│ │ │ │ │ ├── useListings.ts
│ │ │ │ │ ├── useLoginModal.ts
│ │ │ │ │ └── useReservations.ts
│ │ │ │ ├── libs
│ │ │ │ │ ├── axios.ts
│ │ │ │ │ └── fetcher.ts
│ │ │ │ └── types
│ │ │ │ │ └── index.ts
│ │ │ ├── components
│ │ │ │ ├── Button.tsx
│ │ │ │ ├── Container.tsx
│ │ │ │ ├── Heading.tsx
│ │ │ │ ├── HeartButton.tsx
│ │ │ │ └── listings
│ │ │ │ │ └── ListingCard.tsx
│ │ │ ├── custom.d.ts
│ │ │ ├── expose.tsx
│ │ │ ├── globals.css
│ │ │ ├── index.ts
│ │ │ └── trips.tsx
│ │ │ ├── tailwind.config.js
│ │ │ ├── tsconfig.json
│ │ │ └── webpack.config.js
│ ├── package.json
│ └── tsconfig.base.json
├── react-rollup-ts
│ ├── .gitignore
│ ├── package.json
│ ├── rollup.config.mjs
│ ├── src
│ │ ├── App.tsx
│ │ ├── assets
│ │ │ ├── react.svg
│ │ │ └── rollup.svg
│ │ ├── index.tsx
│ │ ├── styles.css
│ │ └── types.d.ts
│ └── tsconfig.json
├── react-rspack-tractor-2.0
│ ├── .gitignore
│ ├── .prettierrc
│ ├── README.md
│ ├── apps
│ │ ├── app
│ │ │ ├── index.html
│ │ │ ├── package.json
│ │ │ ├── rspack.config.js
│ │ │ ├── src
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── index.tsx
│ │ │ │ ├── router.tsx
│ │ │ │ └── style.css
│ │ │ └── tsconfig.json
│ │ ├── checkout
│ │ │ ├── index.html
│ │ │ ├── package.json
│ │ │ ├── rspack.config.js
│ │ │ ├── src
│ │ │ │ ├── AddToCart.tsx
│ │ │ │ ├── CartPage.tsx
│ │ │ │ ├── Checkout.tsx
│ │ │ │ ├── MiniCart.tsx
│ │ │ │ ├── Thanks.tsx
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── components
│ │ │ │ │ ├── Button.tsx
│ │ │ │ │ ├── CompactHeader.tsx
│ │ │ │ │ └── LineItem.tsx
│ │ │ │ ├── css
│ │ │ │ │ ├── AddToCart.css
│ │ │ │ │ ├── Button.css
│ │ │ │ │ ├── CartPage.css
│ │ │ │ │ ├── Checkout.css
│ │ │ │ │ ├── CompactHeader.css
│ │ │ │ │ ├── LineItem.css
│ │ │ │ │ ├── MiniCart.css
│ │ │ │ │ ├── Thanks.css
│ │ │ │ │ └── index.css
│ │ │ │ ├── data
│ │ │ │ │ ├── db.json
│ │ │ │ │ └── store.ts
│ │ │ │ ├── index.tsx
│ │ │ │ ├── js
│ │ │ │ │ └── utils.ts
│ │ │ │ ├── router.tsx
│ │ │ │ └── style.css
│ │ │ └── tsconfig.json
│ │ ├── decide
│ │ │ ├── index.html
│ │ │ ├── package.json
│ │ │ ├── rspack.config.js
│ │ │ ├── src
│ │ │ │ ├── ProductPage.tsx
│ │ │ │ ├── bootstrap.tsx
│ │ │ │ ├── components
│ │ │ │ │ └── VariantOption.tsx
│ │ │ │ ├── css
│ │ │ │ │ ├── ProductPage.css
│ │ │ │ │ ├── VariantOption.css
│ │ │ │ │ └── index.css
│ │ │ │ ├── data
│ │ │ │ │ └── db.json
│ │ │ │ ├── index.tsx
│ │ │ │ ├── js
│ │ │ │ │ └── utils.ts
│ │ │ │ ├── router.tsx
│ │ │ │ └── style.css
│ │ │ └── tsconfig.json
│ │ └── explore
│ │ │ ├── index.html
│ │ │ ├── package.json
│ │ │ ├── rspack.config.js
│ │ │ ├── src
│ │ │ ├── CategoryPage.tsx
│ │ │ ├── Footer.tsx
│ │ │ ├── Header.tsx
│ │ │ ├── HomePage.tsx
│ │ │ ├── Recommendations.tsx
│ │ │ ├── StorePicker.tsx
│ │ │ ├── StoresPage.tsx
│ │ │ ├── bootstrap.tsx
│ │ │ ├── components
│ │ │ │ ├── Button.tsx
│ │ │ │ ├── Filter.tsx
│ │ │ │ ├── Navigation.tsx
│ │ │ │ ├── Product.tsx
│ │ │ │ ├── Recommendation.tsx
│ │ │ │ └── Store.tsx
│ │ │ ├── css
│ │ │ │ ├── Button.css
│ │ │ │ ├── CategoryPage.css
│ │ │ │ ├── Filter.css
│ │ │ │ ├── Footer.css
│ │ │ │ ├── Header.css
│ │ │ │ ├── HomePage.css
│ │ │ │ ├── Navigation.css
│ │ │ │ ├── Product.css
│ │ │ │ ├── Recommendation.css
│ │ │ │ ├── Recommendations.css
│ │ │ │ ├── StorePicker.css
│ │ │ │ ├── StoresPage.css
│ │ │ │ └── index.css
│ │ │ ├── data
│ │ │ │ └── db.json
│ │ │ ├── index.tsx
│ │ │ ├── js
│ │ │ │ └── utils.ts
│ │ │ ├── router.tsx
│ │ │ └── style.css
│ │ │ └── tsconfig.json
│ └── package.json
├── react-tractor-sample
│ ├── .gitignore
│ ├── .npmrc
│ ├── README.md
│ ├── apps
│ │ ├── team-blue
│ │ │ ├── .babelrc
│ │ │ ├── .eslintrc.json
│ │ │ ├── jest.config.ts
│ │ │ ├── package.json
│ │ │ ├── project.json
│ │ │ ├── src
│ │ │ │ ├── app
│ │ │ │ │ ├── app.tsx
│ │ │ │ │ ├── team-blue-basket.tsx
│ │ │ │ │ └── team-blue-buy.tsx
│ │ │ │ ├── assets
│ │ │ │ │ └── .gitkeep
│ │ │ │ ├── index.html
│ │ │ │ ├── main.tsx
│ │ │ │ └── styles.css
│ │ │ ├── tsconfig.app.json
│ │ │ ├── tsconfig.json
│ │ │ ├── tsconfig.spec.json
│ │ │ └── webpack.config.ts
│ │ ├── team-green
│ │ │ ├── .babelrc
│ │ │ ├── .eslintrc.json
│ │ │ ├── jest.config.ts
│ │ │ ├── package.json
│ │ │ ├── project.json
│ │ │ ├── src
│ │ │ │ ├── app
│ │ │ │ │ ├── app.tsx
│ │ │ │ │ ├── team-green-recos-v2.tsx
│ │ │ │ │ └── team-green-recos.tsx
│ │ │ │ ├── assets
│ │ │ │ │ ├── .gitkeep
│ │ │ │ │ └── team-green
│ │ │ │ │ │ └── images
│ │ │ │ │ │ ├── reco_1.jpg
│ │ │ │ │ │ ├── reco_2.jpg
│ │ │ │ │ │ ├── reco_3.jpg
│ │ │ │ │ │ ├── reco_4.jpg
│ │ │ │ │ │ ├── reco_5.jpg
│ │ │ │ │ │ ├── reco_6.jpg
│ │ │ │ │ │ ├── reco_7.jpg
│ │ │ │ │ │ ├── reco_8.jpg
│ │ │ │ │ │ └── reco_9.jpg
│ │ │ │ ├── favicon.ico
│ │ │ │ ├── index.html
│ │ │ │ ├── main.tsx
│ │ │ │ └── styles.css
│ │ │ ├── tsconfig.app.json
│ │ │ ├── tsconfig.json
│ │ │ ├── tsconfig.spec.json
│ │ │ └── webpack.config.ts
│ │ └── team-red
│ │ │ ├── .babelrc
│ │ │ ├── .eslintrc.json
│ │ │ ├── @mf-types
│ │ │ ├── index.d.ts
│ │ │ ├── team_blue
│ │ │ │ ├── BlueBasket.d.ts
│ │ │ │ ├── BlueBuy.d.ts
│ │ │ │ ├── apis.d.ts
│ │ │ │ └── compiled-types
│ │ │ │ │ └── apps
│ │ │ │ │ └── team-blue
│ │ │ │ │ └── src
│ │ │ │ │ └── app
│ │ │ │ │ ├── team-blue-basket.d.ts
│ │ │ │ │ └── team-blue-buy.d.ts
│ │ │ └── team_green
│ │ │ │ ├── GreenRecos.d.ts
│ │ │ │ ├── apis.d.ts
│ │ │ │ └── compiled-types
│ │ │ │ └── apps
│ │ │ │ └── team-green
│ │ │ │ └── src
│ │ │ │ └── app
│ │ │ │ └── team-green-recos.d.ts
│ │ │ ├── jest.config.ts
│ │ │ ├── package.json
│ │ │ ├── project.json
│ │ │ ├── src
│ │ │ ├── app
│ │ │ │ ├── app.tsx
│ │ │ │ └── team-red-layout.tsx
│ │ │ ├── assets
│ │ │ │ ├── .gitkeep
│ │ │ │ ├── team-green
│ │ │ │ │ └── images
│ │ │ │ │ │ ├── reco_1.jpg
│ │ │ │ │ │ ├── reco_2.jpg
│ │ │ │ │ │ ├── reco_3.jpg
│ │ │ │ │ │ ├── reco_4.jpg
│ │ │ │ │ │ ├── reco_5.jpg
│ │ │ │ │ │ ├── reco_6.jpg
│ │ │ │ │ │ ├── reco_7.jpg
│ │ │ │ │ │ ├── reco_8.jpg
│ │ │ │ │ │ └── reco_9.jpg
│ │ │ │ └── team-red
│ │ │ │ │ └── images
│ │ │ │ │ ├── tractor-blue-thumb.jpg
│ │ │ │ │ ├── tractor-blue.jpg
│ │ │ │ │ ├── tractor-green-thumb.jpg
│ │ │ │ │ ├── tractor-green.jpg
│ │ │ │ │ ├── tractor-red-thumb.jpg
│ │ │ │ │ └── tractor-red.jpg
│ │ │ ├── favicon.ico
│ │ │ ├── index.html
│ │ │ ├── main.tsx
│ │ │ └── styles.css
│ │ │ ├── tsconfig.app.json
│ │ │ ├── tsconfig.json
│ │ │ ├── tsconfig.spec.json
│ │ │ └── webpack.config.ts
│ ├── package.json
│ └── tsconfig.json
├── react-vite-mf
│ ├── .gitignore
│ ├── host
│ │ ├── .gitignore
│ │ ├── README.md
│ │ ├── eslint.config.js
│ │ ├── index.html
│ │ ├── package.json
│ │ ├── public
│ │ │ └── vite.svg
│ │ ├── src
│ │ │ ├── App.css
│ │ │ ├── App.tsx
│ │ │ ├── assets
│ │ │ │ └── react.svg
│ │ │ ├── bootstrap.tsx
│ │ │ ├── index.css
│ │ │ ├── main.tsx
│ │ │ └── vite-env.d.ts
│ │ ├── tsconfig.app.json
│ │ ├── tsconfig.app.tsbuildinfo
│ │ ├── tsconfig.json
│ │ ├── tsconfig.node.json
│ │ ├── tsconfig.node.tsbuildinfo
│ │ └── vite.config.ts
│ ├── image.png
│ ├── package.json
│ ├── readme.md
│ ├── remote
│ │ ├── .gitignore
│ │ ├── eslint.config.js
│ │ ├── index.html
│ │ ├── package.json
│ │ ├── public
│ │ │ └── vite.svg
│ │ ├── src
│ │ │ ├── App.css
│ │ │ ├── App.tsx
│ │ │ ├── Button.css
│ │ │ ├── Button.tsx
│ │ │ ├── assets
│ │ │ │ └── react.svg
│ │ │ ├── bootstrap.tsx
│ │ │ ├── index.css
│ │ │ ├── main.tsx
│ │ │ └── vite-env.d.ts
│ │ ├── tsconfig.app.json
│ │ ├── tsconfig.app.tsbuildinfo
│ │ ├── tsconfig.json
│ │ ├── tsconfig.node.json
│ │ ├── tsconfig.node.tsbuildinfo
│ │ └── vite.config.ts
│ ├── rspack
│ │ ├── .babelrc
│ │ ├── .gitignore
│ │ ├── compilation.config.js
│ │ ├── package.json
│ │ ├── postcss.config.js
│ │ ├── rspack.config.js
│ │ ├── src
│ │ │ ├── App.tsx
│ │ │ ├── Image.tsx
│ │ │ ├── assets
│ │ │ │ └── rspack-logo.png
│ │ │ ├── global.d.ts
│ │ │ ├── index.css
│ │ │ ├── index.html
│ │ │ └── index.tsx
│ │ ├── tailwind.config.js
│ │ └── tsconfig.json
│ └── webpack
│ │ ├── .babelrc
│ │ ├── .gitignore
│ │ ├── compilation.config.js
│ │ ├── package.json
│ │ ├── postcss.config.js
│ │ ├── src
│ │ ├── App.tsx
│ │ ├── Image.tsx
│ │ ├── assets
│ │ │ └── webpack-logo.png
│ │ ├── global.d.ts
│ │ ├── index.html
│ │ ├── index.scss
│ │ └── index.ts
│ │ ├── tailwind.config.js
│ │ ├── tsconfig.json
│ │ └── webpack.config.js
├── react-vite-nx
│ ├── .gitignore
│ ├── .prettierignore
│ ├── .prettierrc
│ ├── README.md
│ ├── eslint.config.js
│ ├── index.html
│ ├── nx.json
│ ├── package.json
│ ├── project.json
│ ├── public
│ │ └── favicon.ico
│ ├── src
│ │ ├── app
│ │ │ ├── app.module.css
│ │ │ ├── app.spec.tsx
│ │ │ ├── app.tsx
│ │ │ └── nx-welcome.tsx
│ │ ├── assets
│ │ │ └── .gitkeep
│ │ ├── main.tsx
│ │ └── styles.css
│ ├── tsconfig.app.json
│ ├── tsconfig.json
│ ├── tsconfig.spec.json
│ └── vite.config.ts
├── react-vite-ts
│ ├── .eslintrc.cjs
│ ├── .gitignore
│ ├── README.md
│ ├── index.html
│ ├── package.json
│ ├── public
│ │ └── vite.svg
│ ├── src
│ │ ├── App.css
│ │ ├── App.tsx
│ │ ├── assets
│ │ │ └── react.svg
│ │ ├── index.css
│ │ ├── main.tsx
│ │ └── vite-env.d.ts
│ ├── tsconfig.json
│ ├── tsconfig.node.json
│ └── vite.config.ts
├── rolldown-react
│ ├── package.json
│ ├── pnpm-lock.yaml
│ ├── rolldown.config.mjs
│ ├── src
│ │ ├── App.tsx
│ │ └── main.tsx
│ └── tsconfig.json
├── rspack-project
│ ├── .gitignore
│ ├── index.html
│ ├── package.json
│ ├── rspack.config.mjs
│ └── src
│ │ ├── App.css
│ │ ├── App.jsx
│ │ ├── assets
│ │ └── react.svg
│ │ ├── index.css
│ │ └── main.jsx
├── solid
│ ├── .gitignore
│ ├── README.md
│ ├── index.html
│ ├── package.json
│ ├── public
│ │ └── vite.svg
│ ├── src
│ │ ├── App.css
│ │ ├── App.tsx
│ │ ├── assets
│ │ │ └── solid.svg
│ │ ├── index.css
│ │ ├── index.tsx
│ │ └── vite-env.d.ts
│ ├── tsconfig.app.json
│ ├── tsconfig.json
│ ├── tsconfig.node.json
│ └── vite.config.ts
├── svelte
│ ├── .gitignore
│ ├── README.md
│ ├── index.html
│ ├── package.json
│ ├── public
│ │ └── vite.svg
│ ├── src
│ │ ├── App.svelte
│ │ ├── app.css
│ │ ├── assets
│ │ │ └── svelte.svg
│ │ ├── lib
│ │ │ └── Counter.svelte
│ │ ├── main.ts
│ │ └── vite-env.d.ts
│ ├── svelte.config.js
│ ├── tsconfig.app.json
│ ├── tsconfig.json
│ ├── tsconfig.node.json
│ └── vite.config.ts
└── turbo-rspack-mf
│ ├── .gitignore
│ ├── .npmrc
│ ├── README.md
│ ├── apps
│ ├── home
│ │ ├── .gitignore
│ │ ├── README.md
│ │ ├── index.html
│ │ ├── module-federation.config.ts
│ │ ├── package.json
│ │ ├── postcss.config.mjs
│ │ ├── rspack.config.ts
│ │ ├── src
│ │ │ ├── App.css
│ │ │ ├── RemoteEntry.tsx
│ │ │ ├── bootstrap.css
│ │ │ ├── bootstrap.tsx
│ │ │ ├── main.tsx
│ │ │ └── react-env.d.ts
│ │ ├── tailwind.config.ts
│ │ └── tsconfig.json
│ ├── host
│ │ ├── .gitignore
│ │ ├── README.md
│ │ ├── index.html
│ │ ├── module-federation.config.ts
│ │ ├── package.json
│ │ ├── postcss.config.mjs
│ │ ├── rspack.config.ts
│ │ ├── src
│ │ │ ├── App.tsx
│ │ │ ├── bootstrap.css
│ │ │ ├── bootstrap.tsx
│ │ │ ├── components
│ │ │ │ ├── AppLayout.tsx
│ │ │ │ └── Header.tsx
│ │ │ ├── main.tsx
│ │ │ ├── react-env.d.ts
│ │ │ └── useLocalStorage.ts
│ │ ├── tailwind.config.ts
│ │ ├── tsconfig.json
│ │ └── turbo.json
│ └── settings
│ │ ├── .gitignore
│ │ ├── README.md
│ │ ├── index.html
│ │ ├── module-federation.config.ts
│ │ ├── package.json
│ │ ├── postcss.config.mjs
│ │ ├── rspack.config.ts
│ │ ├── src
│ │ ├── RemoteEntry.tsx
│ │ ├── bootstrap.css
│ │ ├── bootstrap.tsx
│ │ ├── main.tsx
│ │ └── react-env.d.ts
│ │ ├── tailwind.config.ts
│ │ └── tsconfig.json
│ ├── biome.json
│ ├── package.json
│ ├── packages
│ ├── config-tailwind
│ │ ├── package.json
│ │ ├── tailwind.config.ts
│ │ └── tsconfig.json
│ ├── typescript-config
│ │ ├── base.json
│ │ ├── mf-tsconfig.json
│ │ ├── nextjs.json
│ │ ├── package.json
│ │ └── react-library.json
│ └── ui
│ │ ├── package.json
│ │ ├── src
│ │ ├── button.tsx
│ │ ├── card.tsx
│ │ ├── code.tsx
│ │ └── header.tsx
│ │ ├── tsconfig.json
│ │ ├── tsconfig.lint.json
│ │ └── turbo
│ │ └── generators
│ │ ├── config.ts
│ │ └── templates
│ │ └── component.hbs
│ ├── pnpm-workspace.yaml
│ └── turbo.json
├── package.json
├── pnpm-lock.yaml
├── pnpm-workspace.yaml
└── scripts
├── .gitignore
├── README.md
├── package.json
└── src
├── build-packages.js
├── config.js
├── upgrade-plugins.js
└── utils.js
/.editorconfig:
--------------------------------------------------------------------------------
1 | # Editor configuration, see http://editorconfig.org
2 | root = true
3 |
4 | [*]
5 | charset = utf-8
6 | indent_style = space
7 | indent_size = 2
8 | insert_final_newline = true
9 | trim_trailing_whitespace = true
10 |
11 | [*.md]
12 | max_line_length = off
13 | trim_trailing_whitespace = false
14 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | dist
3 | out
4 | .next
5 |
6 | # env vars
7 | .env*
8 | !.env.example
9 | .idea
10 | .DS_Store
11 |
12 | # ignore nx cache
13 | .nx
14 | */.nx
15 |
16 | # ignore build output
17 |
18 | dist
19 | */dist
20 |
21 | # Module Federation Enhanced generated types
22 | */.__mf__temp
23 | */**/.__mf__temp
24 |
25 | .parcel-cache
26 |
--------------------------------------------------------------------------------
/examples/angular-vite/README.md:
--------------------------------------------------------------------------------
1 | # Angular Vite Zephyr Template
2 |
3 | A minimal application that uses Angular + Vite + Zephyr for development and building.
4 |
5 | ## Setup
6 |
7 | ```bash
8 | npm install
9 | ```
10 |
11 | ## Development
12 |
13 | ```bash
14 | npm run dev
15 | ```
16 |
17 | Navigate to http://localhost:5173 to see the running application
18 |
19 | ## Build
20 |
21 | ```bash
22 | npm run build
23 | ```
24 |
25 | ## Preview
26 |
27 | ```bash
28 | npm run preview
29 | ```
30 |
--------------------------------------------------------------------------------
/examples/angular-vite/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Vite + Angular
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/examples/angular-vite/src/main.ts:
--------------------------------------------------------------------------------
1 | import '@angular/compiler';
2 | import 'zone.js';
3 | import { bootstrapApplication } from '@angular/platform-browser';
4 |
5 | import { AppComponent } from './app.component';
6 |
7 | bootstrapApplication(AppComponent);
8 |
--------------------------------------------------------------------------------
/examples/angular-vite/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/angular-vite/tsconfig.app.json:
--------------------------------------------------------------------------------
1 | /* To learn more about this file see: https://angular.io/config/tsconfig. */
2 | {
3 | "extends": "./tsconfig.json",
4 | "compilerOptions": {
5 | "outDir": "./out-tsc/app",
6 | "types": []
7 | },
8 | "files": ["src/main.ts"],
9 | "include": [
10 | "src/**/*.d.ts"
11 | ]
12 | }
13 |
--------------------------------------------------------------------------------
/examples/angular-vite/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from 'vite';
2 | import angular from '@analogjs/vite-plugin-angular';
3 | import { withZephyr } from 'vite-plugin-zephyr';
4 |
5 | // https://vitejs.dev/config/
6 | export default defineConfig(() => ({
7 | plugins: [angular(), withZephyr()],
8 | }));
9 |
--------------------------------------------------------------------------------
/examples/basehref-examples/rspack-app/.gitignore:
--------------------------------------------------------------------------------
1 | # Local
2 | .DS_Store
3 | *.local
4 | *.log*
5 |
6 | # Dist
7 | node_modules
8 | dist/
9 |
10 | # IDE
11 | .vscode/*
12 | !.vscode/extensions.json
13 | .idea
14 |
--------------------------------------------------------------------------------
/examples/basehref-examples/rspack-app/README.md:
--------------------------------------------------------------------------------
1 | # Rspack project
2 |
3 | ## Setup
4 |
5 | Install the dependencies:
6 |
7 | ```bash
8 | npm install
9 | ```
10 |
11 | ## Get started
12 |
13 | Start the dev server:
14 |
15 | ```bash
16 | npm run dev
17 | ```
18 |
19 | Build the app for production:
20 |
21 | ```bash
22 | npm run build
23 | ```
24 |
--------------------------------------------------------------------------------
/examples/basehref-examples/rspack-app/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Rspack + React + TS
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/basehref-examples/rspack-app/src/main.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import App from './App.tsx';
4 | import './index.css';
5 |
6 | ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
7 |
8 |
9 |
10 | );
11 |
--------------------------------------------------------------------------------
/examples/basehref-examples/vite-app/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | BaseHref Vite Example
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/basehref-examples/vite-app/public/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/basehref-examples/vite-app/public/.gitkeep
--------------------------------------------------------------------------------
/examples/basehref-examples/vite-app/src/main.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import App from './App';
4 | import './index.css';
5 |
6 | ReactDOM.createRoot(document.getElementById('root')!).render(
7 |
8 |
9 |
10 | );
11 |
--------------------------------------------------------------------------------
/examples/basehref-examples/vite-app/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "composite": true,
4 | "skipLibCheck": true,
5 | "module": "ESNext",
6 | "moduleResolution": "bundler",
7 | "allowSyntheticDefaultImports": true
8 | },
9 | "include": ["vite.config.ts"]
10 | }
11 |
--------------------------------------------------------------------------------
/examples/basehref-examples/vite-app/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from 'vite';
2 | import react from '@vitejs/plugin-react';
3 | import { withZephyr } from 'vite-plugin-zephyr';
4 |
5 | // https://vitejs.dev/config/
6 | export default defineConfig({
7 | base: '/',
8 | plugins: [react(), withZephyr() as any],
9 | resolve: {
10 | alias: {
11 | '@': '/src',
12 | },
13 | },
14 | });
15 |
--------------------------------------------------------------------------------
/examples/basehref-examples/webpack-app/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | BaseHref Webpack Example
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/examples/basehref-examples/webpack-app/src/index.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import App from './App';
4 | import './styles.css';
5 |
6 | const rootElement = document.getElementById('root');
7 | if (rootElement) {
8 | const root = ReactDOM.createRoot(rootElement);
9 | root.render(
10 |
11 |
12 |
13 | );
14 | }
15 |
--------------------------------------------------------------------------------
/examples/create-default-webpack-mf/app1/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | App 1
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/examples/create-default-webpack-mf/app1/src/bootstrap.js:
--------------------------------------------------------------------------------
1 | import App from "./App";
2 | import React from "react";
3 | import ReactDOM from "react-dom";
4 |
5 | ReactDOM.render(, document.getElementById("root"));
6 |
--------------------------------------------------------------------------------
/examples/create-default-webpack-mf/app1/src/index.js:
--------------------------------------------------------------------------------
1 | // You can write your own logic here to determine the actual url
2 | window.app2Url = ""
3 |
4 | // Use dynamic import here to allow webpack to interface with module federation code
5 | import("./bootstrap");
6 |
--------------------------------------------------------------------------------
/examples/create-default-webpack-mf/app2/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | App 2
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/examples/create-default-webpack-mf/app2/src/App.js:
--------------------------------------------------------------------------------
1 | import React from "react";
2 |
3 | const App = () => {
4 | return (
5 |
11 |
App 2
12 |
13 | )
14 | }
15 |
16 | export default App;
17 |
18 |
--------------------------------------------------------------------------------
/examples/create-default-webpack-mf/app2/src/bootstrap.js:
--------------------------------------------------------------------------------
1 | import React from "react";
2 | import ReactDOM from "react-dom";
3 |
4 | import App from "./App";
5 |
6 | ReactDOM.render(, document.getElementById("root"));
7 |
--------------------------------------------------------------------------------
/examples/create-default-webpack-mf/app2/src/index.js:
--------------------------------------------------------------------------------
1 | import("./bootstrap");
--------------------------------------------------------------------------------
/examples/create-default-webpack-mf/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "create-default-webpack-mf",
3 | "version": "0.0.1",
4 | "scripts": {
5 | "build": "pnpm --filter=./app2 build && pnpm --filter=./app1 build"
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/examples/create-mf-app-rspack/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": ["@babel/preset-typescript", "@babel/preset-react", "@babel/preset-env"],
3 | "plugins": [
4 | ["@babel/transform-runtime"]
5 | ]
6 | }
7 |
--------------------------------------------------------------------------------
/examples/create-mf-app-rspack/src/index.css:
--------------------------------------------------------------------------------
1 | body {
2 | font-family: Arial, Helvetica, sans-serif;
3 | }
4 |
5 | .container {
6 | font-size: 3rem;
7 | margin: auto;
8 | max-width: 800px;
9 | margin-top: 20px;
10 | }
--------------------------------------------------------------------------------
/examples/create-mf-app-rspack/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | create-mf-app-rspack
8 |
9 |
10 |
11 | Module federation rspack example
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/examples/create-mf-app-rspack/src/index.ts:
--------------------------------------------------------------------------------
1 | import("./App");
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/.editorconfig:
--------------------------------------------------------------------------------
1 | # Editor configuration, see http://editorconfig.org
2 | root = true
3 |
4 | [*]
5 | charset = utf-8
6 | indent_style = space
7 | indent_size = 2
8 | insert_final_newline = true
9 | trim_trailing_whitespace = true
10 |
11 | [*.md]
12 | max_line_length = off
13 | trim_trailing_whitespace = false
14 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/.eslintignore:
--------------------------------------------------------------------------------
1 | node_modules
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/.prettierignore:
--------------------------------------------------------------------------------
1 | # Add files here to ignore them from prettier formatting
2 | /dist
3 | /coverage
4 | /.nx/cache
5 | /.nx/workspace-data
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "singleQuote": true
3 | }
4 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host-e2e/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:cypress/recommended", "../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | }
9 | ]
10 | }
11 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host-e2e/cypress.config.ts:
--------------------------------------------------------------------------------
1 | import { nxE2EPreset } from '@nx/cypress/plugins/cypress-preset';
2 |
3 | import { defineConfig } from 'cypress';
4 |
5 | export default defineConfig({
6 | e2e: {
7 | ...nxE2EPreset(__filename, { cypressDir: 'src' }),
8 | baseUrl: 'http://localhost:4200',
9 | },
10 | });
11 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host-e2e/src/e2e/app.cy.ts:
--------------------------------------------------------------------------------
1 | import { getGreeting } from '../support/app.po';
2 |
3 | describe('host-e2e', () => {
4 | beforeEach(() => cy.visit('/'));
5 |
6 | it('should display welcome message', () => {
7 | // Custom command example, see `../support/commands.ts` file
8 | cy.login('my-email@something.com', 'myPassword');
9 |
10 | // Function helper example, see `../support/app.po.ts` file
11 | getGreeting().contains(/Welcome/);
12 | });
13 | });
14 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host-e2e/src/fixtures/example.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Using fixtures to represent data",
3 | "email": "hello@cypress.io",
4 | "body": "Fixtures are a great way to mock data for responses to routes"
5 | }
6 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host-e2e/src/support/app.po.ts:
--------------------------------------------------------------------------------
1 | export const getGreeting = () => cy.get('h1');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host-e2e/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "../../tsconfig.base.json",
3 | "compilerOptions": {
4 | "allowJs": true,
5 | "outDir": "../../dist/out-tsc",
6 | "module": "commonjs",
7 | "types": ["cypress", "node"],
8 | "sourceMap": false
9 | },
10 | "include": [
11 | "**/*.ts",
12 | "**/*.js",
13 | "cypress.config.ts",
14 | "**/*.cy.ts",
15 | "**/*.cy.tsx",
16 | "**/*.cy.js",
17 | "**/*.cy.jsx",
18 | "**/*.d.ts"
19 | ]
20 | }
21 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:@nx/react", "../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | },
9 | {
10 | "files": ["*.ts", "*.tsx"],
11 | "rules": {}
12 | },
13 | {
14 | "files": ["*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ]
18 | }
19 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/jest.config.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | export default {
3 | displayName: 'host',
4 | preset: '../../jest.preset.js',
5 | transform: {
6 | '^(?!.*\\.(js|jsx|ts|tsx|css|json)$)': '@nx/react/plugins/jest',
7 | '^.+\\.[tj]sx?$': ['babel-jest', { presets: ['@nx/react/babel'] }],
8 | },
9 | moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
10 | coverageDirectory: '../../coverage/apps/host',
11 | };
12 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "host",
3 | "version": "0.0.0"
4 | }
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/src/app/app.module.css:
--------------------------------------------------------------------------------
1 | /* Your styles goes here. */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-rspack-workspace-mf/apps/host/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import * as ReactDOM from 'react-dom/client';
3 | import { BrowserRouter } from 'react-router-dom';
4 |
5 | import App from './app/app';
6 |
7 | const root = ReactDOM.createRoot(
8 | document.getElementById('root') as HTMLElement,
9 | );
10 | root.render(
11 |
12 |
13 |
14 |
15 | ,
16 | );
17 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/src/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-rspack-workspace-mf/apps/host/src/favicon.ico
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Host
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/src/main.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap').catch(err => console.error(err));
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/host/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "jsx": "react-jsx",
4 | "allowJs": false,
5 | "esModuleInterop": false,
6 | "allowSyntheticDefaultImports": true,
7 | "strict": true
8 | },
9 | "files": [],
10 | "include": [],
11 | "references": [
12 | {
13 | "path": "./tsconfig.app.json"
14 | },
15 | {
16 | "path": "./tsconfig.spec.json"
17 | }
18 | ],
19 | "extends": "../../tsconfig.base.json"
20 | }
21 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1-e2e/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:cypress/recommended", "../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | }
9 | ]
10 | }
11 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1-e2e/cypress.config.ts:
--------------------------------------------------------------------------------
1 | import { nxE2EPreset } from '@nx/cypress/plugins/cypress-preset';
2 |
3 | import { defineConfig } from 'cypress';
4 |
5 | export default defineConfig({
6 | e2e: {
7 | ...nxE2EPreset(__filename, { cypressDir: 'src' }),
8 | baseUrl: 'http://localhost:4201',
9 | },
10 | });
11 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1-e2e/src/e2e/app.cy.ts:
--------------------------------------------------------------------------------
1 | import { getGreeting } from '../support/app.po';
2 |
3 | describe('remote1-e2e', () => {
4 | beforeEach(() => cy.visit('/'));
5 |
6 | it('should display welcome message', () => {
7 | // Custom command example, see `../support/commands.ts` file
8 | cy.login('my-email@something.com', 'myPassword');
9 |
10 | // Function helper example, see `../support/app.po.ts` file
11 | getGreeting().contains(/Welcome/);
12 | });
13 | });
14 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1-e2e/src/fixtures/example.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Using fixtures to represent data",
3 | "email": "hello@cypress.io",
4 | "body": "Fixtures are a great way to mock data for responses to routes"
5 | }
6 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1-e2e/src/support/app.po.ts:
--------------------------------------------------------------------------------
1 | export const getGreeting = () => cy.get('h1');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1-e2e/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "../../tsconfig.base.json",
3 | "compilerOptions": {
4 | "allowJs": true,
5 | "outDir": "../../dist/out-tsc",
6 | "module": "commonjs",
7 | "types": ["cypress", "node"],
8 | "sourceMap": false
9 | },
10 | "include": [
11 | "**/*.ts",
12 | "**/*.js",
13 | "cypress.config.ts",
14 | "**/*.cy.ts",
15 | "**/*.cy.tsx",
16 | "**/*.cy.js",
17 | "**/*.cy.jsx",
18 | "**/*.d.ts"
19 | ]
20 | }
21 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:@nx/react", "../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | },
9 | {
10 | "files": ["*.ts", "*.tsx"],
11 | "rules": {}
12 | },
13 | {
14 | "files": ["*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ]
18 | }
19 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/jest.config.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | export default {
3 | displayName: 'remote1',
4 | preset: '../../jest.preset.js',
5 | transform: {
6 | '^(?!.*\\.(js|jsx|ts|tsx|css|json)$)': '@nx/react/plugins/jest',
7 | '^.+\\.[tj]sx?$': ['babel-jest', { presets: ['@nx/react/babel'] }],
8 | },
9 | moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
10 | coverageDirectory: '../../coverage/apps/remote1',
11 | };
12 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/module-federation.config.ts:
--------------------------------------------------------------------------------
1 | import { ModuleFederationConfig } from '@nx/rspack/module-federation';
2 |
3 | const config: ModuleFederationConfig = {
4 | name: 'remote1',
5 |
6 | exposes: {
7 | './Module': './src/remote-entry.ts',
8 | },
9 | };
10 |
11 | export default config;
12 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "remote1",
3 | "version": "0.0.0"
4 | }
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/rspack.config.prod.ts:
--------------------------------------------------------------------------------
1 | export default require('./rspack.config');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/app/app.module.css:
--------------------------------------------------------------------------------
1 | /* Your styles goes here. */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/app/app.spec.tsx:
--------------------------------------------------------------------------------
1 | import { render } from '@testing-library/react';
2 |
3 | import App from './app';
4 |
5 | describe('App', () => {
6 | it('should render successfully', () => {
7 | const { baseElement } = render();
8 | expect(baseElement).toBeTruthy();
9 | });
10 |
11 | it('should have a greeting as the title', () => {
12 | const { getByText } = render();
13 | expect(getByText(/Welcome remote1/gi)).toBeTruthy();
14 | });
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/app/app.tsx:
--------------------------------------------------------------------------------
1 | // eslint-disable-next-line @typescript-eslint/no-unused-vars
2 | import styles from './app.module.css';
3 |
4 | import NxWelcome from './nx-welcome';
5 |
6 | export function App() {
7 | return (
8 |
9 |
10 |
11 | );
12 | }
13 |
14 | export default App;
15 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-rspack-workspace-mf/apps/remote1/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import * as ReactDOM from 'react-dom/client';
3 |
4 | import App from './app/app';
5 |
6 | const root = ReactDOM.createRoot(
7 | document.getElementById('root') as HTMLElement,
8 | );
9 | root.render(
10 |
11 |
12 | ,
13 | );
14 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-rspack-workspace-mf/apps/remote1/src/favicon.ico
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Remote1
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/main.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/remote-entry.ts:
--------------------------------------------------------------------------------
1 | export { default } from './app/app';
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote1/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "jsx": "react-jsx",
4 | "allowJs": false,
5 | "esModuleInterop": false,
6 | "allowSyntheticDefaultImports": true,
7 | "strict": true
8 | },
9 | "files": [],
10 | "include": [],
11 | "references": [
12 | {
13 | "path": "./tsconfig.app.json"
14 | },
15 | {
16 | "path": "./tsconfig.spec.json"
17 | }
18 | ],
19 | "extends": "../../tsconfig.base.json"
20 | }
21 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2-e2e/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:cypress/recommended", "../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | }
9 | ]
10 | }
11 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2-e2e/cypress.config.ts:
--------------------------------------------------------------------------------
1 | import { nxE2EPreset } from '@nx/cypress/plugins/cypress-preset';
2 |
3 | import { defineConfig } from 'cypress';
4 |
5 | export default defineConfig({
6 | e2e: {
7 | ...nxE2EPreset(__filename, { cypressDir: 'src' }),
8 | baseUrl: 'http://localhost:4202',
9 | },
10 | });
11 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2-e2e/src/e2e/app.cy.ts:
--------------------------------------------------------------------------------
1 | import { getGreeting } from '../support/app.po';
2 |
3 | describe('remote2-e2e', () => {
4 | beforeEach(() => cy.visit('/'));
5 |
6 | it('should display welcome message', () => {
7 | // Custom command example, see `../support/commands.ts` file
8 | cy.login('my-email@something.com', 'myPassword');
9 |
10 | // Function helper example, see `../support/app.po.ts` file
11 | getGreeting().contains(/Welcome/);
12 | });
13 | });
14 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2-e2e/src/fixtures/example.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Using fixtures to represent data",
3 | "email": "hello@cypress.io",
4 | "body": "Fixtures are a great way to mock data for responses to routes"
5 | }
6 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2-e2e/src/support/app.po.ts:
--------------------------------------------------------------------------------
1 | export const getGreeting = () => cy.get('h1');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2-e2e/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "../../tsconfig.base.json",
3 | "compilerOptions": {
4 | "allowJs": true,
5 | "outDir": "../../dist/out-tsc",
6 | "module": "commonjs",
7 | "types": ["cypress", "node"],
8 | "sourceMap": false
9 | },
10 | "include": [
11 | "**/*.ts",
12 | "**/*.js",
13 | "cypress.config.ts",
14 | "**/*.cy.ts",
15 | "**/*.cy.tsx",
16 | "**/*.cy.js",
17 | "**/*.cy.jsx",
18 | "**/*.d.ts"
19 | ]
20 | }
21 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:@nx/react", "../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | },
9 | {
10 | "files": ["*.ts", "*.tsx"],
11 | "rules": {}
12 | },
13 | {
14 | "files": ["*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ]
18 | }
19 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/jest.config.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | export default {
3 | displayName: 'remote2',
4 | preset: '../../jest.preset.js',
5 | transform: {
6 | '^(?!.*\\.(js|jsx|ts|tsx|css|json)$)': '@nx/react/plugins/jest',
7 | '^.+\\.[tj]sx?$': ['babel-jest', { presets: ['@nx/react/babel'] }],
8 | },
9 | moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
10 | coverageDirectory: '../../coverage/apps/remote2',
11 | };
12 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/module-federation.config.ts:
--------------------------------------------------------------------------------
1 | import { ModuleFederationConfig } from '@nx/rspack/module-federation';
2 |
3 | const config: ModuleFederationConfig = {
4 | name: 'remote2',
5 |
6 | exposes: {
7 | './Module': './src/remote-entry.ts',
8 | },
9 | };
10 |
11 | export default config;
12 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "remote2",
3 | "version": "0.0.0"
4 | }
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/rspack.config.prod.ts:
--------------------------------------------------------------------------------
1 | export default require('./rspack.config');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/app/app.module.css:
--------------------------------------------------------------------------------
1 | /* Your styles goes here. */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/app/app.spec.tsx:
--------------------------------------------------------------------------------
1 | import { render } from '@testing-library/react';
2 |
3 | import App from './app';
4 |
5 | describe('App', () => {
6 | it('should render successfully', () => {
7 | const { baseElement } = render();
8 | expect(baseElement).toBeTruthy();
9 | });
10 |
11 | it('should have a greeting as the title', () => {
12 | const { getByText } = render();
13 | expect(getByText(/Welcome remote2/gi)).toBeTruthy();
14 | });
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/app/app.tsx:
--------------------------------------------------------------------------------
1 | // eslint-disable-next-line @typescript-eslint/no-unused-vars
2 | import styles from './app.module.css';
3 |
4 | import NxWelcome from './nx-welcome';
5 |
6 | export function App() {
7 | return (
8 |
9 |
10 |
11 | );
12 | }
13 |
14 | export default App;
15 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-rspack-workspace-mf/apps/remote2/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import * as ReactDOM from 'react-dom/client';
3 |
4 | import App from './app/app';
5 |
6 | const root = ReactDOM.createRoot(
7 | document.getElementById('root') as HTMLElement,
8 | );
9 | root.render(
10 |
11 |
12 | ,
13 | );
14 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-rspack-workspace-mf/apps/remote2/src/favicon.ico
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Remote2
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/main.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/remote-entry.ts:
--------------------------------------------------------------------------------
1 | export { default } from './app/app';
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/apps/remote2/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "jsx": "react-jsx",
4 | "allowJs": false,
5 | "esModuleInterop": false,
6 | "allowSyntheticDefaultImports": true,
7 | "strict": true
8 | },
9 | "files": [],
10 | "include": [],
11 | "references": [
12 | {
13 | "path": "./tsconfig.app.json"
14 | },
15 | {
16 | "path": "./tsconfig.spec.json"
17 | }
18 | ],
19 | "extends": "../../tsconfig.base.json"
20 | }
21 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/jest.config.ts:
--------------------------------------------------------------------------------
1 | import { getJestProjectsAsync } from '@nx/jest';
2 |
3 | export default async () => ({
4 | projects: await getJestProjectsAsync(),
5 | });
6 |
--------------------------------------------------------------------------------
/examples/create-nx-rspack-workspace-mf/jest.preset.js:
--------------------------------------------------------------------------------
1 | const nxPreset = require('@nx/jest/preset').default;
2 |
3 | module.exports = { ...nxPreset };
4 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/.editorconfig:
--------------------------------------------------------------------------------
1 | # Editor configuration, see http://editorconfig.org
2 | root = true
3 |
4 | [*]
5 | charset = utf-8
6 | indent_style = space
7 | indent_size = 2
8 | insert_final_newline = true
9 | trim_trailing_whitespace = true
10 |
11 | [*.md]
12 | max_line_length = off
13 | trim_trailing_whitespace = false
14 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/.eslintignore:
--------------------------------------------------------------------------------
1 | node_modules
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/.prettierignore:
--------------------------------------------------------------------------------
1 | # Add files here to ignore them from prettier formatting
2 | /dist
3 | /coverage
4 | /.nx/cache
5 | /.nx/workspace-data
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "singleQuote": true
3 | }
4 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": [
3 | "nrwl.angular-console",
4 | "esbenp.prettier-vscode",
5 | "firsttris.vscode-jest-runner"
6 | ]
7 | }
8 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": [
3 | [
4 | "@nx/react/babel",
5 | {
6 | "runtime": "automatic"
7 | }
8 | ]
9 | ],
10 | "plugins": []
11 | }
12 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:@nx/react", "../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | },
9 | {
10 | "files": ["*.ts", "*.tsx"],
11 | "rules": {}
12 | },
13 | {
14 | "files": ["*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ]
18 | }
19 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/jest.config.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | export default {
3 | displayName: 'remote1',
4 | preset: '../../jest.preset.js',
5 | transform: {
6 | '^(?!.*\\.(js|jsx|ts|tsx|css|json)$)': '@nx/react/plugins/jest',
7 | '^.+\\.[tj]sx?$': ['babel-jest', { presets: ['@nx/react/babel'] }],
8 | },
9 | moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
10 | coverageDirectory: '../../coverage/apps/remote1',
11 | };
12 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/module-federation.config.ts:
--------------------------------------------------------------------------------
1 | import { ModuleFederationConfig } from '@nx/webpack';
2 |
3 | const config: ModuleFederationConfig = {
4 | name: 'remote1',
5 |
6 | exposes: {
7 | './Module': './src/remote-entry.ts',
8 | },
9 | };
10 |
11 | export default config;
12 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "remote1",
3 | "version": "0.0.1"
4 | }
5 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/app/app.module.css:
--------------------------------------------------------------------------------
1 | /* Your styles goes here. */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/app/app.spec.tsx:
--------------------------------------------------------------------------------
1 | import { render } from '@testing-library/react';
2 |
3 | import App from './app';
4 |
5 | describe('App', () => {
6 | it('should render successfully', () => {
7 | const { baseElement } = render();
8 | expect(baseElement).toBeTruthy();
9 | });
10 |
11 | it('should have a greeting as the title', () => {
12 | const { getByText } = render();
13 | expect(getByText(/Welcome remote1/gi)).toBeTruthy();
14 | });
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/app/app.tsx:
--------------------------------------------------------------------------------
1 | // eslint-disable-next-line @typescript-eslint/no-unused-vars
2 | import styles from './app.module.css';
3 |
4 | import NxWelcome from './nx-welcome';
5 |
6 | export function App() {
7 | return (
8 |
9 |
10 |
11 | );
12 | }
13 |
14 | export default App;
15 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-workspace-mf/apps/remote1/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import * as ReactDOM from 'react-dom/client';
3 |
4 | import App from './app/app';
5 |
6 | const root = ReactDOM.createRoot(
7 | document.getElementById('root') as HTMLElement
8 | );
9 | root.render(
10 |
11 |
12 |
13 | );
14 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-workspace-mf/apps/remote1/src/favicon.ico
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Remote1
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/main.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/remote-entry.ts:
--------------------------------------------------------------------------------
1 | export { default } from './app/app';
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "jsx": "react-jsx",
4 | "allowJs": false,
5 | "esModuleInterop": false,
6 | "allowSyntheticDefaultImports": true,
7 | "strict": true
8 | },
9 | "files": [],
10 | "include": [],
11 | "references": [
12 | {
13 | "path": "./tsconfig.app.json"
14 | },
15 | {
16 | "path": "./tsconfig.spec.json"
17 | }
18 | ],
19 | "extends": "../../tsconfig.base.json"
20 | }
21 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote1/webpack.config.prod.ts:
--------------------------------------------------------------------------------
1 | export default require('./webpack.config');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": [
3 | [
4 | "@nx/react/babel",
5 | {
6 | "runtime": "automatic"
7 | }
8 | ]
9 | ],
10 | "plugins": []
11 | }
12 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:@nx/react", "../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | },
9 | {
10 | "files": ["*.ts", "*.tsx"],
11 | "rules": {}
12 | },
13 | {
14 | "files": ["*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ]
18 | }
19 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/jest.config.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | export default {
3 | displayName: 'remote2',
4 | preset: '../../jest.preset.js',
5 | transform: {
6 | '^(?!.*\\.(js|jsx|ts|tsx|css|json)$)': '@nx/react/plugins/jest',
7 | '^.+\\.[tj]sx?$': ['babel-jest', { presets: ['@nx/react/babel'] }],
8 | },
9 | moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
10 | coverageDirectory: '../../coverage/apps/remote2',
11 | };
12 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/module-federation.config.ts:
--------------------------------------------------------------------------------
1 | import { ModuleFederationConfig } from '@nx/webpack';
2 |
3 | const config: ModuleFederationConfig = {
4 | name: 'remote2',
5 |
6 | exposes: {
7 | './Module': './src/remote-entry.ts',
8 | },
9 | };
10 |
11 | export default config;
12 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "remote2",
3 | "version": "0.0.1"
4 | }
5 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/app/app.module.css:
--------------------------------------------------------------------------------
1 | /* Your styles goes here. */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/app/app.spec.tsx:
--------------------------------------------------------------------------------
1 | import { render } from '@testing-library/react';
2 |
3 | import App from './app';
4 |
5 | describe('App', () => {
6 | it('should render successfully', () => {
7 | const { baseElement } = render();
8 | expect(baseElement).toBeTruthy();
9 | });
10 |
11 | it('should have a greeting as the title', () => {
12 | const { getByText } = render();
13 | expect(getByText(/Welcome remote2/gi)).toBeTruthy();
14 | });
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/app/app.tsx:
--------------------------------------------------------------------------------
1 | // eslint-disable-next-line @typescript-eslint/no-unused-vars
2 | import styles from './app.module.css';
3 |
4 | import NxWelcome from './nx-welcome';
5 |
6 | export function App() {
7 | return (
8 |
9 |
10 |
11 | );
12 | }
13 |
14 | export default App;
15 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-workspace-mf/apps/remote2/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import * as ReactDOM from 'react-dom/client';
3 |
4 | import App from './app/app';
5 |
6 | const root = ReactDOM.createRoot(
7 | document.getElementById('root') as HTMLElement
8 | );
9 | root.render(
10 |
11 |
12 |
13 | );
14 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-workspace-mf/apps/remote2/src/favicon.ico
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Remote2
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/main.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/remote-entry.ts:
--------------------------------------------------------------------------------
1 | export { default } from './app/app';
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "jsx": "react-jsx",
4 | "allowJs": false,
5 | "esModuleInterop": false,
6 | "allowSyntheticDefaultImports": true,
7 | "strict": true
8 | },
9 | "files": [],
10 | "include": [],
11 | "references": [
12 | {
13 | "path": "./tsconfig.app.json"
14 | },
15 | {
16 | "path": "./tsconfig.spec.json"
17 | }
18 | ],
19 | "extends": "../../tsconfig.base.json"
20 | }
21 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/remote2/webpack.config.prod.ts:
--------------------------------------------------------------------------------
1 | export default require('./webpack.config');
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": [
3 | [
4 | "@nx/react/babel",
5 | {
6 | "runtime": "automatic"
7 | }
8 | ]
9 | ],
10 | "plugins": []
11 | }
12 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:@nx/react", "../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | },
9 | {
10 | "files": ["*.ts", "*.tsx"],
11 | "rules": {}
12 | },
13 | {
14 | "files": ["*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ]
18 | }
19 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/jest.config.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | export default {
3 | displayName: 'shell',
4 | preset: '../../jest.preset.js',
5 | transform: {
6 | '^(?!.*\\.(js|jsx|ts|tsx|css|json)$)': '@nx/react/plugins/jest',
7 | '^.+\\.[tj]sx?$': ['babel-jest', { presets: ['@nx/react/babel'] }],
8 | },
9 | moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
10 | coverageDirectory: '../../coverage/apps/shell',
11 | };
12 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "shell",
3 | "version": "0.0.1"
4 | }
5 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/src/app/app.module.css:
--------------------------------------------------------------------------------
1 | /* Your styles goes here. */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-workspace-mf/apps/shell/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import * as ReactDOM from 'react-dom/client';
3 | import { BrowserRouter } from 'react-router-dom';
4 |
5 | import App from './app/app';
6 |
7 | const root = ReactDOM.createRoot(
8 | document.getElementById('root') as HTMLElement
9 | );
10 | root.render(
11 |
12 |
13 |
14 |
15 |
16 | );
17 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/src/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/create-nx-workspace-mf/apps/shell/src/favicon.ico
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Shell
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/src/main.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap').catch((err) => console.error(err));
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/apps/shell/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "jsx": "react-jsx",
4 | "allowJs": false,
5 | "esModuleInterop": false,
6 | "allowSyntheticDefaultImports": true,
7 | "strict": true
8 | },
9 | "files": [],
10 | "include": [],
11 | "references": [
12 | {
13 | "path": "./tsconfig.app.json"
14 | },
15 | {
16 | "path": "./tsconfig.spec.json"
17 | }
18 | ],
19 | "extends": "../../tsconfig.base.json"
20 | }
21 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/jest.config.ts:
--------------------------------------------------------------------------------
1 | import { getJestProjectsAsync } from '@nx/jest';
2 |
3 | export default async () => ({
4 | projects: await getJestProjectsAsync(),
5 | });
6 |
--------------------------------------------------------------------------------
/examples/create-nx-workspace-mf/jest.preset.js:
--------------------------------------------------------------------------------
1 | const nxPreset = require('@nx/jest/preset').default;
2 |
3 | module.exports = { ...nxPreset };
4 |
--------------------------------------------------------------------------------
/examples/modernjs-app/src/modern-app-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 | ///
3 | ///
4 |
--------------------------------------------------------------------------------
/examples/modernjs-app/src/modern.runtime.ts:
--------------------------------------------------------------------------------
1 | import { defineRuntimeConfig } from '@modern-js/runtime';
2 |
3 | export default defineRuntimeConfig({});
4 |
--------------------------------------------------------------------------------
/examples/modernjs-app/src/routes/layout.tsx:
--------------------------------------------------------------------------------
1 | import { Outlet } from '@modern-js/runtime/router';
2 |
3 | export default function Layout() {
4 | return (
5 |
6 |
7 |
8 | );
9 | }
10 |
--------------------------------------------------------------------------------
/examples/modernjs-app/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@modern-js/tsconfig/base",
3 | "compilerOptions": {
4 | "declaration": false,
5 | "jsx": "preserve",
6 | "baseUrl": "./",
7 | "paths": {
8 | "@/*": ["./src/*"],
9 | "@shared/*": ["./shared/*"]
10 | }
11 | },
12 | "include": ["src", "shared", "config", "modern.config.ts"],
13 | "exclude": ["**/node_modules"]
14 | }
15 |
--------------------------------------------------------------------------------
/examples/nx-ng/.eslintignore:
--------------------------------------------------------------------------------
1 | node_modules
2 |
--------------------------------------------------------------------------------
/examples/nx-ng/.prettierignore:
--------------------------------------------------------------------------------
1 | # Add files here to ignore them from prettier formatting
2 | /dist
3 | /coverage
4 | .angular
5 |
6 | /.nx/cache
7 | /.nx/workspace-data
--------------------------------------------------------------------------------
/examples/nx-ng/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "singleQuote": true
3 | }
4 |
--------------------------------------------------------------------------------
/examples/nx-ng/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": [
3 | "nrwl.angular-console",
4 | "esbenp.prettier-vscode",
5 | "firsttris.vscode-jest-runner",
6 | "dbaeumer.vscode-eslint"
7 | ]
8 | }
9 |
--------------------------------------------------------------------------------
/examples/nx-ng/e2e/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:cypress/recommended"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.js", "*.jsx"],
7 | "extends": ["plugin:@nx/javascript"],
8 | "rules": {
9 | "@typescript-eslint/no-extra-semi": "error",
10 | "no-extra-semi": "off"
11 | }
12 | },
13 | {
14 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ],
18 | "plugins": ["@nx"]
19 | }
20 |
--------------------------------------------------------------------------------
/examples/nx-ng/e2e/cypress.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from 'cypress';
2 | import { nxE2EPreset } from '@nx/cypress/plugins/cypress-preset';
3 |
4 | export default defineConfig({
5 | e2e: nxE2EPreset(__dirname),
6 | });
7 |
--------------------------------------------------------------------------------
/examples/nx-ng/e2e/src/e2e/app.cy.ts:
--------------------------------------------------------------------------------
1 | import { getGreeting } from '../support/app.po';
2 |
3 | describe('nx-ng', () => {
4 | beforeEach(() => cy.visit('/'));
5 |
6 | it('should display welcome message', () => {
7 | // Custom command example, see `../support/commands.ts` file
8 | cy.login('my-email@something.com', 'myPassword');
9 |
10 | // Function helper example, see `../support/app.po.ts` file
11 | getGreeting().contains('Welcome nx-ng');
12 | });
13 | });
14 |
--------------------------------------------------------------------------------
/examples/nx-ng/e2e/src/fixtures/example.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Using fixtures to represent data",
3 | "email": "hello@cypress.io"
4 | }
5 |
--------------------------------------------------------------------------------
/examples/nx-ng/e2e/src/support/app.po.ts:
--------------------------------------------------------------------------------
1 | export const getGreeting = () => cy.get('h1');
2 |
--------------------------------------------------------------------------------
/examples/nx-ng/extra-webpack.config.js:
--------------------------------------------------------------------------------
1 | const {withZephyr} = require('zephyr-webpack-plugin');
2 |
3 | // shorthand for: module.exports = (config) => withZephyr({wait_for_index_html: true})(config);
4 | module.exports = withZephyr({wait_for_index_html: true});
5 |
6 |
--------------------------------------------------------------------------------
/examples/nx-ng/index-html-transform.js:
--------------------------------------------------------------------------------
1 | const { resolveIndexHtml, onDeploymentDone } = require('zephyr-webpack-plugin');
2 |
3 | module.exports = async (targetOptions, indexHtml) => {
4 | resolveIndexHtml(indexHtml);
5 | await onDeploymentDone();
6 | return indexHtml;
7 | };
8 |
9 |
10 |
--------------------------------------------------------------------------------
/examples/nx-ng/jest.preset.js:
--------------------------------------------------------------------------------
1 | const nxPreset = require('@nx/jest/preset').default;
2 |
3 | module.exports = { ...nxPreset };
4 |
--------------------------------------------------------------------------------
/examples/nx-ng/src/app/app.component.css:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/nx-ng/src/app/app.component.css
--------------------------------------------------------------------------------
/examples/nx-ng/src/app/app.component.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/examples/nx-ng/src/app/app.component.ts:
--------------------------------------------------------------------------------
1 | import { Component } from '@angular/core';
2 | import { RouterModule } from '@angular/router';
3 | import { NxWelcomeComponent } from './nx-welcome.component';
4 |
5 | @Component({
6 | standalone: true,
7 | imports: [NxWelcomeComponent, RouterModule],
8 | selector: 'nx-ng-root',
9 | templateUrl: './app.component.html',
10 | styleUrls: ['./app.component.css'],
11 | })
12 | export class AppComponent {
13 | title = 'nx-ng';
14 | }
15 |
--------------------------------------------------------------------------------
/examples/nx-ng/src/app/app.config.ts:
--------------------------------------------------------------------------------
1 | import { ApplicationConfig } from '@angular/core';
2 | import {
3 | provideRouter,
4 | withEnabledBlockingInitialNavigation,
5 | } from '@angular/router';
6 | import { appRoutes } from './app.routes';
7 | export const appConfig: ApplicationConfig = {
8 | providers: [provideRouter(appRoutes, withEnabledBlockingInitialNavigation())],
9 | };
10 |
--------------------------------------------------------------------------------
/examples/nx-ng/src/app/app.routes.ts:
--------------------------------------------------------------------------------
1 | import { Route } from '@angular/router';
2 |
3 | export const appRoutes: Route[] = [];
4 |
--------------------------------------------------------------------------------
/examples/nx-ng/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/nx-ng/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/nx-ng/src/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/nx-ng/src/favicon.ico
--------------------------------------------------------------------------------
/examples/nx-ng/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | nx-ng
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/nx-ng/src/main.ts:
--------------------------------------------------------------------------------
1 | import { appConfig } from './app/app.config';
2 | import { bootstrapApplication } from '@angular/platform-browser';
3 |
4 | import { AppComponent } from './app/app.component';
5 |
6 | bootstrapApplication(AppComponent, appConfig).catch((err) =>
7 | console.error(err)
8 | );
9 |
--------------------------------------------------------------------------------
/examples/nx-ng/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/nx-ng/src/test-setup.ts:
--------------------------------------------------------------------------------
1 | import 'jest-preset-angular/setup-jest';
2 |
--------------------------------------------------------------------------------
/examples/nx-ng/tsconfig.app.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "./tsconfig.json",
3 | "compilerOptions": {
4 | "outDir": "./dist/out-tsc",
5 | "types": []
6 | },
7 | "files": ["src/main.ts"],
8 | "include": ["src/**/*.d.ts"],
9 | "exclude": ["jest.config.ts", "src/**/*.test.ts", "src/**/*.spec.ts"]
10 | }
11 |
--------------------------------------------------------------------------------
/examples/nx-ng/tsconfig.editor.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "./tsconfig.json",
3 | "include": ["src/**/*.ts"],
4 | "compilerOptions": {
5 | "types": ["jest", "node"]
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/examples/nx-ng/tsconfig.spec.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "./tsconfig.json",
3 | "compilerOptions": {
4 | "outDir": "./dist/out-tsc",
5 | "module": "commonjs",
6 | "target": "es2016",
7 | "types": ["jest", "node"]
8 | },
9 | "files": ["src/test-setup.ts"],
10 | "include": [
11 | "jest.config.ts",
12 | "src/**/*.test.ts",
13 | "src/**/*.spec.ts",
14 | "src/**/*.d.ts"
15 | ]
16 | }
17 |
--------------------------------------------------------------------------------
/examples/parcel-react/.parcelrc:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@parcel/config-default",
3 | "reporters": [
4 | "parcel-reporter-zephyr"
5 | ]
6 | }
7 |
--------------------------------------------------------------------------------
/examples/parcel-react/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Zephyr + Parcel
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/examples/parcel-react/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "parcel-react",
3 | "version": "1.0.0",
4 | "description": "",
5 | "scripts": {
6 | "dev": "parcel index.html",
7 | "build": "parcel build index.html"
8 | },
9 | "dependencies": {
10 | "react": "^19.0.0",
11 | "react-dom": "^19.0.0"
12 | },
13 | "devDependencies": {
14 | "@parcel/config-default": "2.13.3",
15 | "parcel": "2.13.3",
16 | "parcel-reporter-zephyr": "catalog:zephyr",
17 | "typescript": "^5.7.3"
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/parcel-react/src/App.tsx:
--------------------------------------------------------------------------------
1 | export function App() {
2 | return Hello Zephyr + Parcel!
;
3 | }
4 |
--------------------------------------------------------------------------------
/examples/parcel-react/src/index.tsx:
--------------------------------------------------------------------------------
1 | import { createRoot } from 'react-dom/client';
2 | import { App } from './App';
3 |
4 | const container = document.getElementById('app')!;
5 | const root = createRoot(container);
6 | root.render();
7 |
--------------------------------------------------------------------------------
/examples/qwik-1.5/netlify.toml:
--------------------------------------------------------------------------------
1 | [build]
2 | publish = "dist"
3 | command = "npm run build"
4 |
--------------------------------------------------------------------------------
/examples/qwik-1.5/public/_headers:
--------------------------------------------------------------------------------
1 | /build/*
2 | Cache-Control: public, max-age=31536000, s-maxage=31536000, immutable
3 |
--------------------------------------------------------------------------------
/examples/qwik-1.5/public/fonts/poppins-400.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/qwik-1.5/public/fonts/poppins-400.woff2
--------------------------------------------------------------------------------
/examples/qwik-1.5/public/fonts/poppins-500.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/qwik-1.5/public/fonts/poppins-500.woff2
--------------------------------------------------------------------------------
/examples/qwik-1.5/public/fonts/poppins-700.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/qwik-1.5/public/fonts/poppins-700.woff2
--------------------------------------------------------------------------------
/examples/qwik-1.5/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://json.schemastore.org/web-manifest-combined.json",
3 | "name": "qwik-project-name",
4 | "short_name": "Welcome to Qwik",
5 | "start_url": ".",
6 | "display": "standalone",
7 | "background_color": "#fff",
8 | "description": "A Qwik project app."
9 | }
10 |
--------------------------------------------------------------------------------
/examples/qwik-1.5/public/robots.txt:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/qwik-1.5/public/robots.txt
--------------------------------------------------------------------------------
/examples/qwik-1.5/src/components/starter/counter/counter.module.css:
--------------------------------------------------------------------------------
1 | .counter-wrapper {
2 | margin-top: 50px;
3 | display: flex;
4 | align-items: center;
5 | justify-content: center;
6 | gap: 10px;
7 | }
8 |
9 | @media screen and (min-width: 768px) {
10 | .counter-wrapper {
11 | gap: 30px;
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/examples/qwik-1.5/src/components/starter/footer/footer.module.css:
--------------------------------------------------------------------------------
1 | .anchor {
2 | color: white !important;
3 | display: block;
4 | font-size: 0.8rem;
5 | text-align: center;
6 | text-decoration: none;
7 | line-height: 1.5;
8 | }
9 |
10 | .anchor span:not(.spacer) {
11 | display: block;
12 | }
13 |
14 | .spacer {
15 | display: none;
16 | padding: 0 15px;
17 | }
18 |
19 | @media screen and (min-width: 768px) {
20 | .anchor span {
21 | display: inline !important;
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/examples/qwik-1.5/src/components/starter/gauge/gauge.module.css:
--------------------------------------------------------------------------------
1 | .wrapper {
2 | position: relative;
3 | }
4 |
5 | .gauge {
6 | width: 160px;
7 | }
8 |
9 | .value {
10 | position: absolute;
11 | top: 50%;
12 | left: 50%;
13 | color: white;
14 | font-size: 3rem;
15 | transform: translate(-50%, -50%);
16 | width: 200px;
17 | text-align: center;
18 | }
19 |
20 | @media screen and (min-width: 768px) {
21 | .gauge {
22 | width: 400px;
23 | }
24 | .value {
25 | font-size: 7rem;
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/examples/qwik-1.5/src/components/starter/infobox/infobox.module.css:
--------------------------------------------------------------------------------
1 | .infobox {
2 | color: white;
3 | font-size: 0.8rem;
4 | line-height: 2;
5 | margin: 0 0 40px;
6 | }
7 |
8 | .infobox h3 {
9 | font-size: 1rem;
10 | font-weight: 400;
11 | margin: 0 0 15px;
12 | padding: 0;
13 | }
14 |
15 | .infobox li {
16 | line-height: 2.5;
17 | }
18 |
19 | @media screen and (min-width: 600px) {
20 | .infobox {
21 | margin: 0;
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/examples/qwik-1.5/src/components/starter/infobox/infobox.tsx:
--------------------------------------------------------------------------------
1 | import { Slot, component$ } from "@builder.io/qwik";
2 | import styles from "./infobox.module.css";
3 |
4 | export default component$(() => {
5 | return (
6 |
7 |
8 |
9 |
10 |
11 |
12 | );
13 | });
14 |
--------------------------------------------------------------------------------
/examples/qwik-1.5/src/media/thunder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/qwik-1.5/src/media/thunder.png
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/.gitignore:
--------------------------------------------------------------------------------
1 | @mf-types
2 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "plugins": [],
3 | "presets": [["@babel/preset-react", { "runtime": "automatic" }], "@babel/preset-typescript"]
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "airbnb_categories",
3 | "version": "0.1.0",
4 | "private": true,
5 | "scripts": {
6 | "dev": "webpack serve",
7 | "build": "rimraf dist && webpack --mode production",
8 | "start": "http-server dist -p 3011"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/postcss.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | };
7 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/public/assets/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/categories/public/assets/favicon.ico
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/public/images/listing-placeholder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/categories/public/images/listing-placeholder.png
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Host App
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/src/app.tsx:
--------------------------------------------------------------------------------
1 | import { MemoryRouter } from 'react-router-dom';
2 | import Categories from './components/Categories';
3 | import './globals.css';
4 |
5 | export default function App() {
6 | return (
7 |
8 |
9 |
10 | );
11 | }
12 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './app';
4 |
5 | const container = document.getElementById('root');
6 |
7 | createRoot(container!).render(
8 |
9 |
10 | ,
11 | );
12 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/src/components/Container.tsx:
--------------------------------------------------------------------------------
1 | interface ContainerProps {
2 | children: React.ReactNode;
3 | }
4 |
5 | const Container: React.FC = ({ children }) => {
6 | return (
7 |
17 | {children}
18 |
19 | );
20 | };
21 |
22 | export default Container;
23 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/src/expose.tsx:
--------------------------------------------------------------------------------
1 | import './globals.css';
2 | import Categories from './components/Categories';
3 | export default Categories;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/src/globals.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/src/index.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/categories/tailwind.config.js:
--------------------------------------------------------------------------------
1 | /** @type {import('tailwindcss').Config} */
2 | module.exports = {
3 | content: ['./src/**/*.{js,ts,jsx,tsx}'],
4 | theme: {
5 | extend: {},
6 | },
7 | plugins: [],
8 | };
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "plugins": [],
3 | "presets": [["@babel/preset-react", { "runtime": "automatic" }], "@babel/preset-typescript"]
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "airbnb_favorites",
3 | "version": "0.1.0",
4 | "private": true,
5 | "scripts": {
6 | "dev": "webpack serve",
7 | "build": "rimraf dist && webpack --mode production",
8 | "start": "http-server dist -p 3013"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/postcss.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | };
7 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/public/assets/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/favorites/public/assets/favicon.ico
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/public/images/listing-placeholder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/favorites/public/images/listing-placeholder.png
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Host App
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/app.tsx:
--------------------------------------------------------------------------------
1 | import { MemoryRouter } from 'react-router-dom';
2 | import Favorites from './favorites';
3 | import './globals.css';
4 | import { listingsMock, usersMock } from './common/actions/mocks';
5 |
6 | export default function App() {
7 | return (
8 |
9 |
10 |
11 | );
12 | }
13 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './app';
4 |
5 | const container = document.getElementById('root');
6 |
7 | createRoot(container!).render(
8 |
9 |
10 | ,
11 | );
12 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/common/actions/deleteFavorite.ts:
--------------------------------------------------------------------------------
1 | import getCurrentUser from './getCurrentUser';
2 | import saveUser from './saveUser';
3 |
4 | export default function deleteFavorite(listingId: string) {
5 | const currentUser = getCurrentUser();
6 |
7 | if (!currentUser) return false;
8 |
9 | currentUser.favoriteIds = currentUser.favoriteIds.filter((id) => id !== listingId);
10 |
11 | saveUser(currentUser);
12 |
13 | return true;
14 | }
15 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/common/actions/saveUser.ts:
--------------------------------------------------------------------------------
1 | import { User } from '../types';
2 | import { CURRENT_USER_KEY } from './getCurrentUser';
3 |
4 | export default function saveUser(user: User) {
5 | localStorage.setItem(CURRENT_USER_KEY, JSON.stringify(user));
6 | return true;
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/common/hooks/useCurrentUser.ts:
--------------------------------------------------------------------------------
1 | import { CURRENT_USER } from '../libs/axios';
2 | import fetcher from '../libs/fetcher';
3 | import { User } from '../types';
4 | import useSWR from 'swr';
5 |
6 | const useCurrentUser = () => {
7 | const { data, ...rest } = useSWR(CURRENT_USER, fetcher);
8 |
9 | return {
10 | currentUser: data,
11 | ...rest,
12 | };
13 | };
14 |
15 | export default useCurrentUser;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/common/hooks/useLoginModal.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface LoginModalStore {
4 | isOpen: boolean;
5 | onOpen: () => void;
6 | onClose: () => void;
7 | }
8 |
9 | const useLoginModal = create((set) => ({
10 | isOpen: false,
11 | onOpen: () => set({ isOpen: true }),
12 | onClose: () => set({ isOpen: false }),
13 | }));
14 |
15 | export default useLoginModal;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/common/libs/fetcher.ts:
--------------------------------------------------------------------------------
1 | import axios from './axios';
2 |
3 | const fetcher = (url: string) => axios.get(url).then((res) => res.data);
4 |
5 | export default fetcher;
6 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/components/Container.tsx:
--------------------------------------------------------------------------------
1 | interface ContainerProps {
2 | children: React.ReactNode;
3 | }
4 |
5 | const Container: React.FC = ({ children }) => {
6 | return (
7 |
17 | {children}
18 |
19 | );
20 | };
21 |
22 | export default Container;
23 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/custom.d.ts:
--------------------------------------------------------------------------------
1 | declare module '*.png';
2 | declare module '*.jpg';
3 | declare module '*.jpeg';
4 | declare module '*.svg';
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/expose.tsx:
--------------------------------------------------------------------------------
1 | import './globals.css';
2 | import Favorites from './favorites';
3 | export default Favorites;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/globals.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/src/index.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/favorites/tailwind.config.js:
--------------------------------------------------------------------------------
1 | /** @type {import('tailwindcss').Config} */
2 | module.exports = {
3 | content: ['./src/**/*.{js,ts,jsx,tsx}'],
4 | theme: {
5 | extend: {},
6 | },
7 | plugins: [],
8 | };
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "plugins": [],
3 | "presets": [["@babel/preset-react", { "runtime": "automatic" }], "@babel/preset-typescript"]
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "airbnb_home",
3 | "version": "0.1.0",
4 | "private": true,
5 | "scripts": {
6 | "dev": "webpack serve",
7 | "build": "rimraf dist && webpack --mode production",
8 | "start": "http-server dist -p 3012"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/postcss.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | };
7 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/public/assets/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/home/public/assets/favicon.ico
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/public/images/listing-placeholder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/home/public/images/listing-placeholder.png
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Host App
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/app.tsx:
--------------------------------------------------------------------------------
1 | import { MemoryRouter } from 'react-router-dom';
2 | import Home from './home';
3 | import './globals.css';
4 |
5 | export default function App() {
6 | return (
7 |
8 |
9 |
10 | );
11 | }
12 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './app';
4 |
5 | const container = document.getElementById('root');
6 |
7 | createRoot(container!).render(
8 |
9 |
10 | ,
11 | );
12 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/common/actions/saveUser.ts:
--------------------------------------------------------------------------------
1 | import { User } from '../types';
2 | import { CURRENT_USER_KEY } from './getCurrentUser';
3 |
4 | export default function saveUser(user: User) {
5 | localStorage.setItem(CURRENT_USER_KEY, JSON.stringify(user));
6 | return true;
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/common/hooks/useCurrentUser.ts:
--------------------------------------------------------------------------------
1 | import { CURRENT_USER } from '../libs/axios';
2 | import fetcher from '../libs/fetcher';
3 | import { User } from '../types';
4 | import useSWR from 'swr';
5 |
6 | const useCurrentUser = () => {
7 | const { data, ...rest } = useSWR(CURRENT_USER, fetcher);
8 |
9 | return {
10 | currentUser: data,
11 | ...rest,
12 | };
13 | };
14 |
15 | export default useCurrentUser;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/common/hooks/useLoginModal.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface LoginModalStore {
4 | isOpen: boolean;
5 | onOpen: () => void;
6 | onClose: () => void;
7 | }
8 |
9 | const useLoginModal = create((set) => ({
10 | isOpen: false,
11 | onOpen: () => set({ isOpen: true }),
12 | onClose: () => set({ isOpen: false }),
13 | }));
14 |
15 | export default useLoginModal;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/common/libs/fetcher.ts:
--------------------------------------------------------------------------------
1 | import axios from './axios';
2 |
3 | const fetcher = (url: string) => axios.get(url).then((res) => res.data);
4 |
5 | export default fetcher;
6 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/components/Container.tsx:
--------------------------------------------------------------------------------
1 | interface ContainerProps {
2 | children: React.ReactNode;
3 | }
4 |
5 | const Container: React.FC = ({ children }) => {
6 | return (
7 |
17 | {children}
18 |
19 | );
20 | };
21 |
22 | export default Container;
23 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/custom.d.ts:
--------------------------------------------------------------------------------
1 | declare module '*.png';
2 | declare module '*.jpg';
3 | declare module '*.jpeg';
4 | declare module '*.svg';
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/expose.tsx:
--------------------------------------------------------------------------------
1 | import './globals.css';
2 | import Home from './home';
3 | export default Home;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/globals.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/src/index.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/home/tailwind.config.js:
--------------------------------------------------------------------------------
1 | /** @type {import('tailwindcss').Config} */
2 | module.exports = {
3 | content: ['./src/**/*.{js,ts,jsx,tsx}'],
4 | theme: {
5 | extend: {},
6 | },
7 | plugins: [],
8 | };
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "plugins": [],
3 | "presets": [["@babel/preset-react", { "runtime": "automatic" }], "@babel/preset-typescript"]
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "airbnb_properties",
3 | "version": "0.1.0",
4 | "private": true,
5 | "scripts": {
6 | "dev": "webpack serve",
7 | "build": "rimraf dist && webpack --mode production",
8 | "start": "http-server dist -p 3015"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/postcss.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | };
7 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/public/assets/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/properties/public/assets/favicon.ico
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/public/images/listing-placeholder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/properties/public/images/listing-placeholder.png
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Host App
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/app.tsx:
--------------------------------------------------------------------------------
1 | import { MemoryRouter } from 'react-router-dom';
2 | import Properties from './properties';
3 | import './globals.css';
4 | import { listingsMock, usersMock } from './common/actions/mocks';
5 |
6 | export default function App() {
7 | return (
8 |
9 |
10 |
11 | );
12 | }
13 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './app';
4 |
5 | const container = document.getElementById('root');
6 |
7 | createRoot(container!).render(
8 |
9 |
10 | ,
11 | );
12 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/common/actions/saveUser.ts:
--------------------------------------------------------------------------------
1 | import { User } from '../types';
2 | import { CURRENT_USER_KEY } from './getCurrentUser';
3 |
4 | export default function saveUser(user: User) {
5 | localStorage.setItem(CURRENT_USER_KEY, JSON.stringify(user));
6 | return true;
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/common/hooks/useCurrentUser.ts:
--------------------------------------------------------------------------------
1 | import { CURRENT_USER } from '../libs/axios';
2 | import fetcher from '../libs/fetcher';
3 | import { User } from '../types';
4 | import useSWR from 'swr';
5 |
6 | const useCurrentUser = () => {
7 | const { data, ...rest } = useSWR(CURRENT_USER, fetcher);
8 |
9 | return {
10 | currentUser: data,
11 | ...rest,
12 | };
13 | };
14 |
15 | export default useCurrentUser;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/common/hooks/useLoginModal.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface LoginModalStore {
4 | isOpen: boolean;
5 | onOpen: () => void;
6 | onClose: () => void;
7 | }
8 |
9 | const useLoginModal = create((set) => ({
10 | isOpen: false,
11 | onOpen: () => set({ isOpen: true }),
12 | onClose: () => set({ isOpen: false }),
13 | }));
14 |
15 | export default useLoginModal;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/common/libs/fetcher.ts:
--------------------------------------------------------------------------------
1 | import axios from './axios';
2 |
3 | const fetcher = (url: string) => axios.get(url).then((res) => res.data);
4 |
5 | export default fetcher;
6 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/components/Container.tsx:
--------------------------------------------------------------------------------
1 | interface ContainerProps {
2 | children: React.ReactNode;
3 | }
4 |
5 | const Container: React.FC = ({ children }) => {
6 | return (
7 |
17 | {children}
18 |
19 | );
20 | };
21 |
22 | export default Container;
23 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/custom.d.ts:
--------------------------------------------------------------------------------
1 | declare module '*.png';
2 | declare module '*.jpg';
3 | declare module '*.jpeg';
4 | declare module '*.svg';
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/expose.tsx:
--------------------------------------------------------------------------------
1 | import './globals.css';
2 | import Properties from './properties';
3 | export default Properties;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/globals.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
5 | html,
6 | body,
7 | :root {
8 | height: 100%;
9 | }
10 |
11 | .leaflet-bottom,
12 | .leaflet-control,
13 | .leaflet-pane,
14 | .leaflet-top {
15 | z-index: 0 !important;
16 | }
17 |
18 | .rdrMonth {
19 | width: 100% !important;
20 | }
21 |
22 | .rdrCalendarWrapper {
23 | font-size: 16px !important;
24 | width: 100% !important;
25 | }
26 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/src/index.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/properties/tailwind.config.js:
--------------------------------------------------------------------------------
1 | /** @type {import('tailwindcss').Config} */
2 | module.exports = {
3 | content: ['./src/**/*.{js,ts,jsx,tsx}'],
4 | theme: {
5 | extend: {},
6 | },
7 | plugins: [],
8 | };
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "plugins": [],
3 | "presets": [["@babel/preset-react", { "runtime": "automatic" }], "@babel/preset-typescript"]
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "airbnb-react-host",
3 | "version": "0.1.0",
4 | "private": true,
5 | "scripts": {
6 | "dev": "webpack serve",
7 | "build": "rimraf dist && webpack --mode production",
8 | "start": "http-server dist -p 3010"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/postcss.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | };
7 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/public/assets/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/react-host/public/assets/favicon.ico
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/public/images/listing-placeholder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/react-host/public/images/listing-placeholder.png
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/public/images/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/react-host/public/images/logo.png
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/public/images/placeholder.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/react-host/public/images/placeholder.jpg
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Host App
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/_error.tsx:
--------------------------------------------------------------------------------
1 | import { useEffect } from 'react';
2 |
3 | import EmptyState from './components/EmptyState';
4 |
5 | interface ErrorStateProps {
6 | error: Error;
7 | }
8 |
9 | const ErrorState: React.FC = ({ error }) => {
10 | useEffect(() => {
11 | console.error(error);
12 | }, [error]);
13 |
14 | return ;
15 | };
16 |
17 | export default ErrorState;
18 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/actions/deleteFavorite.ts:
--------------------------------------------------------------------------------
1 | import getCurrentUser from './getCurrentUser';
2 | import saveUser from './saveUser';
3 |
4 | export default function deleteFavorite(listingId: string) {
5 | const currentUser = getCurrentUser();
6 |
7 | if (!currentUser) return false;
8 |
9 | currentUser.favoriteIds = currentUser.favoriteIds.filter((id) => id !== listingId);
10 |
11 | saveUser(currentUser);
12 |
13 | return true;
14 | }
15 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/actions/saveUser.ts:
--------------------------------------------------------------------------------
1 | import { User } from '../common/types';
2 | import { CURRENT_USER_KEY } from './getCurrentUser';
3 |
4 | export default function saveUser(user: User) {
5 | localStorage.setItem(CURRENT_USER_KEY, JSON.stringify(user));
6 | return true;
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/hooks/useCurrentUser.ts:
--------------------------------------------------------------------------------
1 | import { CURRENT_USER } from '../libs/axios';
2 | import fetcher from '../libs/fetcher';
3 | import { User } from '../types';
4 | import useSWR from 'swr';
5 |
6 | const useCurrentUser = () => {
7 | const { data, ...rest } = useSWR(CURRENT_USER, fetcher);
8 |
9 | return {
10 | currentUser: data,
11 | ...rest,
12 | };
13 | };
14 |
15 | export default useCurrentUser;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/hooks/useFavorites.ts:
--------------------------------------------------------------------------------
1 | import { FAVORITES } from '../libs/axios';
2 | import fetcher from '../libs/fetcher';
3 | import { Listing } from '../types';
4 | import useSWR from 'swr';
5 |
6 | const useFavorites = () => {
7 | const { data, ...rest } = useSWR(FAVORITES, fetcher);
8 |
9 | return {
10 | favorites: data ?? [],
11 | ...rest,
12 | };
13 | };
14 |
15 | export default useFavorites;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/hooks/useListing.ts:
--------------------------------------------------------------------------------
1 | import { LISTINGS } from '../libs/axios';
2 | import fetcher from '../libs/fetcher';
3 | import { Listing, User } from '../common/types';
4 | import useSWR from 'swr';
5 |
6 | const useListing = (id?: string) => {
7 | const { data, ...rest } = useSWR(LISTINGS + '/' + id, fetcher);
8 |
9 | return {
10 | listing: data,
11 | ...rest,
12 | };
13 | };
14 |
15 | export default useListing;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/hooks/useLoginModal.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface LoginModalStore {
4 | isOpen: boolean;
5 | onOpen: () => void;
6 | onClose: () => void;
7 | }
8 |
9 | const useLoginModal = create((set) => ({
10 | isOpen: false,
11 | onOpen: () => set({ isOpen: true }),
12 | onClose: () => set({ isOpen: false }),
13 | }));
14 |
15 | export default useLoginModal;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/hooks/useRegisterModal.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface RegisterModalStore {
4 | isOpen: boolean;
5 | onOpen: () => void;
6 | onClose: () => void;
7 | }
8 |
9 | const useRegisterModal = create((set) => ({
10 | isOpen: false,
11 | onOpen: () => set({ isOpen: true }),
12 | onClose: () => set({ isOpen: false }),
13 | }));
14 |
15 | export default useRegisterModal;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/hooks/useRentModal.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface RentModalStore {
4 | isOpen: boolean;
5 | onOpen: () => void;
6 | onClose: () => void;
7 | }
8 |
9 | const useRentModal = create((set) => ({
10 | isOpen: false,
11 | onOpen: () => set({ isOpen: true }),
12 | onClose: () => set({ isOpen: false }),
13 | }));
14 |
15 | export default useRentModal;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/hooks/useSearchModal.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface SearchModalStore {
4 | isOpen: boolean;
5 | onOpen: () => void;
6 | onClose: () => void;
7 | }
8 |
9 | const useSearchModal = create((set) => ({
10 | isOpen: false,
11 | onOpen: () => set({ isOpen: true }),
12 | onClose: () => set({ isOpen: false }),
13 | }));
14 |
15 | export default useSearchModal;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/hooks/useShowRemotes.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface ShowRemotesStore {
4 | show: boolean;
5 | toggle: () => void;
6 | }
7 |
8 | const useShowRemotes = create((set) => ({
9 | show: false,
10 | toggle: () => set(({ show }) => ({ show: !show })),
11 | }));
12 |
13 | export default useShowRemotes;
14 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/common/libs/fetcher.ts:
--------------------------------------------------------------------------------
1 | import axios from './axios';
2 |
3 | const fetcher = (url: string) => axios.get(url).then((res) => res.data);
4 |
5 | export default fetcher;
6 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/components/Avatar.tsx:
--------------------------------------------------------------------------------
1 | import placeholder from '../../public/images/placeholder.jpg';
2 |
3 | interface AvatarProps {
4 | src: string | null | undefined;
5 | }
6 |
7 | const Avatar: React.FC = ({ src }) => {
8 | return (
9 |
10 | );
11 | };
12 |
13 | export default Avatar;
14 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/components/Container.tsx:
--------------------------------------------------------------------------------
1 | interface ContainerProps {
2 | children: React.ReactNode;
3 | }
4 |
5 | const Container: React.FC = ({ children }) => {
6 | return (
7 |
17 | {children}
18 |
19 | );
20 | };
21 |
22 | export default Container;
23 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/components/Loader.tsx:
--------------------------------------------------------------------------------
1 | import { PuffLoader } from 'react-spinners';
2 |
3 | const Loader = () => {
4 | return (
5 |
16 | );
17 | };
18 |
19 | export default Loader;
20 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/components/inputs/calendar-styles.css:
--------------------------------------------------------------------------------
1 | @import 'react-date-range/dist/styles.css';
2 | @import 'react-date-range/dist/theme/default.css';
3 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/components/map-styles.css:
--------------------------------------------------------------------------------
1 | @import 'leaflet/dist/leaflet.css';
2 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/components/navbar/Logo.tsx:
--------------------------------------------------------------------------------
1 | import { useNavigate } from 'react-router-dom';
2 | import logo from '../../../public/images/logo.png';
3 |
4 | const Logo = () => {
5 | const navigate = useNavigate();
6 |
7 | return (
8 |
navigate('/')}
10 | className="hidden md:block cursor-pointer"
11 | src={logo}
12 | height="100"
13 | width="100"
14 | alt="Logo"
15 | />
16 | );
17 | };
18 |
19 | export default Logo;
20 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/custom.d.ts:
--------------------------------------------------------------------------------
1 | declare module '*.png';
2 | declare module '*.jpg';
3 | declare module '*.jpeg';
4 | declare module '*.svg';
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/globals.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
5 | html,
6 | body,
7 | :root {
8 | height: 100%;
9 | }
10 |
11 | .leaflet-bottom,
12 | .leaflet-control,
13 | .leaflet-pane,
14 | .leaflet-top {
15 | z-index: 0 !important;
16 | }
17 |
18 | .rdrMonth {
19 | width: 100% !important;
20 | }
21 |
22 | .rdrCalendarWrapper {
23 | font-size: 16px !important;
24 | width: 100% !important;
25 | }
26 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/index.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/src/providers/ToasterProvider.tsx:
--------------------------------------------------------------------------------
1 | import { Toaster } from 'react-hot-toast';
2 |
3 | const ToasterProvider = () => {
4 | return ;
5 | };
6 |
7 | export default ToasterProvider;
8 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/react-host/tailwind.config.js:
--------------------------------------------------------------------------------
1 | /** @type {import('tailwindcss').Config} */
2 | module.exports = {
3 | content: ['./src/**/*.{js,ts,jsx,tsx}'],
4 | theme: {
5 | extend: {},
6 | },
7 | plugins: [],
8 | };
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "plugins": [],
3 | "presets": [["@babel/preset-react", { "runtime": "automatic" }], "@babel/preset-typescript"]
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "airbnb_reservations",
3 | "version": "0.1.0",
4 | "private": true,
5 | "scripts": {
6 | "dev": "webpack serve",
7 | "build": "rimraf dist && webpack --mode production",
8 | "start": "http-server dist -p 3016"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/postcss.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | };
7 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/public/assets/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/reservations/public/assets/favicon.ico
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/public/images/listing-placeholder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/reservations/public/images/listing-placeholder.png
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Host App
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/app.tsx:
--------------------------------------------------------------------------------
1 | import { MemoryRouter } from 'react-router-dom';
2 | import Trips from './reservations';
3 | import './globals.css';
4 | import { usersMock } from './common/actions/mocks';
5 | import getReservations from './common/actions/getReservations';
6 |
7 | export default function App() {
8 | return (
9 |
10 |
11 |
12 | );
13 | }
14 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './app';
4 |
5 | const container = document.getElementById('root');
6 |
7 | createRoot(container!).render(
8 |
9 |
10 | ,
11 | );
12 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/common/actions/saveUser.ts:
--------------------------------------------------------------------------------
1 | import { User } from '../types';
2 | import { CURRENT_USER_KEY } from './getCurrentUser';
3 |
4 | export default function saveUser(user: User) {
5 | localStorage.setItem(CURRENT_USER_KEY, JSON.stringify(user));
6 | return true;
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/common/hooks/useCurrentUser.ts:
--------------------------------------------------------------------------------
1 | import { CURRENT_USER } from '../libs/axios';
2 | import fetcher from '../libs/fetcher';
3 | import { User } from '../types';
4 | import useSWR from 'swr';
5 |
6 | const useCurrentUser = () => {
7 | const { data, ...rest } = useSWR(CURRENT_USER, fetcher);
8 |
9 | return {
10 | currentUser: data,
11 | ...rest,
12 | };
13 | };
14 |
15 | export default useCurrentUser;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/common/hooks/useLoginModal.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface LoginModalStore {
4 | isOpen: boolean;
5 | onOpen: () => void;
6 | onClose: () => void;
7 | }
8 |
9 | const useLoginModal = create((set) => ({
10 | isOpen: false,
11 | onOpen: () => set({ isOpen: true }),
12 | onClose: () => set({ isOpen: false }),
13 | }));
14 |
15 | export default useLoginModal;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/common/libs/fetcher.ts:
--------------------------------------------------------------------------------
1 | import axios from './axios';
2 |
3 | const fetcher = (url: string) => axios.get(url).then((res) => res.data);
4 |
5 | export default fetcher;
6 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/components/Container.tsx:
--------------------------------------------------------------------------------
1 | interface ContainerProps {
2 | children: React.ReactNode;
3 | }
4 |
5 | const Container: React.FC = ({ children }) => {
6 | return (
7 |
17 | {children}
18 |
19 | );
20 | };
21 |
22 | export default Container;
23 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/custom.d.ts:
--------------------------------------------------------------------------------
1 | declare module '*.png';
2 | declare module '*.jpg';
3 | declare module '*.jpeg';
4 | declare module '*.svg';
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/expose.tsx:
--------------------------------------------------------------------------------
1 | import './globals.css';
2 | import Reservations from './reservations';
3 | export default Reservations;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/globals.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/src/index.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/reservations/tailwind.config.js:
--------------------------------------------------------------------------------
1 | /** @type {import('tailwindcss').Config} */
2 | module.exports = {
3 | content: ['./src/**/*.{js,ts,jsx,tsx}'],
4 | theme: {
5 | extend: {},
6 | },
7 | plugins: [],
8 | };
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "plugins": [],
3 | "presets": [["@babel/preset-react", { "runtime": "automatic" }], "@babel/preset-typescript"]
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "airbnb_trips",
3 | "version": "0.1.0",
4 | "private": true,
5 | "scripts": {
6 | "dev": "webpack serve",
7 | "build": "rimraf dist && webpack --mode production",
8 | "start": "http-server dist -p 3014"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/postcss.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | };
7 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/public/assets/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/trips/public/assets/favicon.ico
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/public/images/listing-placeholder.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-airbnb-clone/apps/trips/public/images/listing-placeholder.png
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Host App
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/app.tsx:
--------------------------------------------------------------------------------
1 | import { MemoryRouter } from 'react-router-dom';
2 | import Trips from './trips';
3 | import './globals.css';
4 | import { usersMock } from './common/actions/mocks';
5 | import getReservations from './common/actions/getReservations';
6 |
7 | export default function App() {
8 | return (
9 |
10 |
11 |
12 | );
13 | }
14 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './app';
4 |
5 | const container = document.getElementById('root');
6 |
7 | createRoot(container!).render(
8 |
9 |
10 | ,
11 | );
12 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/common/actions/saveUser.ts:
--------------------------------------------------------------------------------
1 | import { User } from '../types';
2 | import { CURRENT_USER_KEY } from './getCurrentUser';
3 |
4 | export default function saveUser(user: User) {
5 | localStorage.setItem(CURRENT_USER_KEY, JSON.stringify(user));
6 | return true;
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/common/hooks/useCurrentUser.ts:
--------------------------------------------------------------------------------
1 | import { CURRENT_USER } from '../libs/axios';
2 | import fetcher from '../libs/fetcher';
3 | import { User } from '../types';
4 | import useSWR from 'swr';
5 |
6 | const useCurrentUser = () => {
7 | const { data, ...rest } = useSWR(CURRENT_USER, fetcher);
8 |
9 | return {
10 | currentUser: data,
11 | ...rest,
12 | };
13 | };
14 |
15 | export default useCurrentUser;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/common/hooks/useLoginModal.ts:
--------------------------------------------------------------------------------
1 | import { create } from 'zustand';
2 |
3 | interface LoginModalStore {
4 | isOpen: boolean;
5 | onOpen: () => void;
6 | onClose: () => void;
7 | }
8 |
9 | const useLoginModal = create((set) => ({
10 | isOpen: false,
11 | onOpen: () => set({ isOpen: true }),
12 | onClose: () => set({ isOpen: false }),
13 | }));
14 |
15 | export default useLoginModal;
16 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/common/libs/fetcher.ts:
--------------------------------------------------------------------------------
1 | import axios from './axios';
2 |
3 | const fetcher = (url: string) => axios.get(url).then((res) => res.data);
4 |
5 | export default fetcher;
6 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/components/Container.tsx:
--------------------------------------------------------------------------------
1 | interface ContainerProps {
2 | children: React.ReactNode;
3 | }
4 |
5 | const Container: React.FC = ({ children }) => {
6 | return (
7 |
17 | {children}
18 |
19 | );
20 | };
21 |
22 | export default Container;
23 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/custom.d.ts:
--------------------------------------------------------------------------------
1 | declare module '*.png';
2 | declare module '*.jpg';
3 | declare module '*.jpeg';
4 | declare module '*.svg';
5 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/expose.tsx:
--------------------------------------------------------------------------------
1 | import './globals.css';
2 | import Trips from './trips';
3 | export default Trips;
4 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/globals.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
5 | html,
6 | body,
7 | :root {
8 | height: 100%;
9 | }
10 |
11 | .leaflet-bottom,
12 | .leaflet-control,
13 | .leaflet-pane,
14 | .leaflet-top {
15 | z-index: 0 !important;
16 | }
17 |
18 | .rdrMonth {
19 | width: 100% !important;
20 | }
21 |
22 | .rdrCalendarWrapper {
23 | font-size: 16px !important;
24 | width: 100% !important;
25 | }
26 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/src/index.ts:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-airbnb-clone/apps/trips/tailwind.config.js:
--------------------------------------------------------------------------------
1 | /** @type {import('tailwindcss').Config} */
2 | module.exports = {
3 | content: ['./src/**/*.{js,ts,jsx,tsx}'],
4 | theme: {
5 | extend: {},
6 | },
7 | plugins: [],
8 | };
9 |
--------------------------------------------------------------------------------
/examples/react-rollup-ts/.gitignore:
--------------------------------------------------------------------------------
1 | dist
2 | node_modules
3 |
--------------------------------------------------------------------------------
/examples/react-rollup-ts/src/index.tsx:
--------------------------------------------------------------------------------
1 | import { createRoot } from "react-dom/client";
2 | import App from "./App";
3 | import "./styles.css";
4 |
5 | document.body.appendChild(
6 | Object.assign(document.createElement(`div`), { id: "root" })
7 | );
8 | createRoot(document.getElementById("root")!).render();
9 |
--------------------------------------------------------------------------------
/examples/react-rollup-ts/src/types.d.ts:
--------------------------------------------------------------------------------
1 | declare module "*.svg";
2 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "printWidth": 120,
3 | "singleQuote": true,
4 | "trailingComma": "all",
5 | "bracketSpacing": true,
6 | "parser": "typescript",
7 | "semi": true,
8 | "jsxBracketSameLine": true
9 | }
10 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/app/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "tractor_v2_app",
3 | "version": "1.0.0",
4 | "scripts": {
5 | "serve": "NODE_ENV=development rspack serve",
6 | "build": "NODE_ENV=production rspack build"
7 | },
8 | "app": "./src/index.html",
9 | "types": "dist/index.d.ts",
10 | "importmap": {
11 | "imports": {},
12 | "inherit": [
13 | "piral-base",
14 | "piral-core"
15 | ]
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/app/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import { RouterProvider } from 'react-router-dom';
4 | import { router } from './router';
5 | import './style.css';
6 |
7 | ReactDOM.createRoot(document.getElementById('app') as HTMLElement).render(
8 |
9 |
10 | ,
11 | );
12 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/app/src/index.tsx:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/checkout/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "tractor_v2_checkout",
3 | "version": "1.0.0",
4 | "scripts": {
5 | "serve": "NODE_ENV=development rspack serve",
6 | "build": "NODE_ENV=production rspack build"
7 | },
8 | "source": "src/index.tsx",
9 | "main": "dist/index.js",
10 | "files": [
11 | "dist"
12 | ],
13 | "importmap": {
14 | "imports": {
15 | "canvas-confetti": "."
16 | },
17 | "inherit": [
18 | "app"
19 | ]
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/checkout/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import { RouterProvider } from 'react-router-dom';
4 | import { router } from './router';
5 | import './css/index.css';
6 | import './style.css';
7 |
8 | ReactDOM.createRoot(document.getElementById('app') as HTMLElement).render(
9 |
10 |
11 | ,
12 | );
13 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/checkout/src/css/Thanks.css:
--------------------------------------------------------------------------------
1 | .c_Thanks {
2 | margin: 0 auto;
3 | max-width: calc(500px + var(--outer-space) * 2);
4 | padding: 0 var(--outer-space);
5 | min-height: 50vh;
6 | }
7 |
8 | .c_Thanks__title {
9 | margin: 4rem 0;
10 | font-size: 40px;
11 | }
12 |
13 | .c_Thanks__text {
14 | margin: 4rem 0;
15 | }
16 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/checkout/src/css/index.css:
--------------------------------------------------------------------------------
1 | @import url("./CartPage.css");
2 | @import url("./Checkout.css");
3 | @import url("./Thanks.css");
4 | @import url("./MiniCart.css");
5 | @import url("./AddToCart.css");
6 | @import url("./LineItem.css");
7 | @import url("./Button.css");
8 | @import url("./CompactHeader.css");
9 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/checkout/src/index.tsx:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/checkout/src/js/utils.ts:
--------------------------------------------------------------------------------
1 | export function src(image: string, size: number) {
2 | return image.replace('[size]', `${size}`);
3 | }
4 |
5 | export function srcset(image: string, sizes: Array = []) {
6 | return sizes.map((size) => `${src(image, size)} ${size}w`).join(', ');
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/decide/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "tractor_v2_decide",
3 | "version": "1.0.0",
4 | "scripts": {
5 | "serve": "NODE_ENV=development rspack serve",
6 | "build": "NODE_ENV=production rspack build"
7 | },
8 | "source": "src/index.tsx",
9 | "main": "dist/index.js",
10 | "files": [
11 | "dist"
12 | ],
13 | "importmap": {
14 | "imports": {},
15 | "inherit": [
16 | "app"
17 | ]
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/decide/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import { RouterProvider } from 'react-router-dom';
4 | import { router } from './router';
5 | import './css/index.css';
6 | import './style.css';
7 |
8 | ReactDOM.createRoot(document.getElementById('app') as HTMLElement).render(
9 |
10 |
11 | ,
12 | );
13 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/decide/src/css/index.css:
--------------------------------------------------------------------------------
1 | @import url("./ProductPage.css");
2 | @import url("./VariantOption.css");
3 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/decide/src/index.tsx:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/decide/src/js/utils.ts:
--------------------------------------------------------------------------------
1 | export function src(image: string, size: number) {
2 | return image.replace('[size]', `${size}`);
3 | }
4 |
5 | export function srcset(image: string, sizes: Array = []) {
6 | return sizes.map((size) => `${src(image, size)} ${size}w`).join(', ');
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/explore/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "tractor_v2_explore",
3 | "version": "1.0.0",
4 | "scripts": {
5 | "serve": "NODE_ENV=development rspack serve",
6 | "build": "NODE_ENV=production rspack build"
7 | },
8 | "source": "src/index.tsx",
9 | "main": "dist/index.js",
10 | "files": [
11 | "dist"
12 | ],
13 | "importmap": {
14 | "imports": {},
15 | "inherit": [
16 | "app"
17 | ]
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/explore/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import { RouterProvider } from 'react-router-dom';
4 | import { router } from './router';
5 | import './css/index.css';
6 | import './style.css';
7 |
8 | ReactDOM.createRoot(document.getElementById('app') as HTMLElement).render(
9 |
10 |
11 | ,
12 | );
13 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/explore/src/css/StoresPage.css:
--------------------------------------------------------------------------------
1 | .e_StoresPage {
2 | max-width: calc(1000px + var(--outer-space) * 2);
3 | padding: 0 var(--outer-space);
4 | margin: 0 auto;
5 | }
6 |
7 | .e_StoresPage_list {
8 | list-style: none;
9 | padding: 0;
10 | margin: 5em 0 4em;
11 | display: flex;
12 | justify-content: space-between;
13 | gap: 2em;
14 | flex-wrap: wrap;
15 | }
16 |
17 | .e_StoresPage p {
18 | max-width: 80ch;
19 | }
20 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/explore/src/css/index.css:
--------------------------------------------------------------------------------
1 | @import url("./Header.css");
2 | @import url("./Navigation.css");
3 | @import url("./Footer.css");
4 | @import url("./StorePicker.css");
5 | @import url("./Product.css");
6 | @import url("./Recommendations.css");
7 | @import url("./Recommendation.css");
8 | @import url("./Button.css");
9 | @import url("./Filter.css");
10 | @import url("./CategoryPage.css");
11 | @import url("./StoresPage.css");
12 | @import url("./HomePage.css");
13 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/explore/src/index.tsx:
--------------------------------------------------------------------------------
1 | import('./bootstrap');
2 |
--------------------------------------------------------------------------------
/examples/react-rspack-tractor-2.0/apps/explore/src/js/utils.ts:
--------------------------------------------------------------------------------
1 | export function src(image: string, size: number) {
2 | return image.replace('[size]', `${size}`);
3 | }
4 |
5 | export function srcset(image: string, sizes: Array = []) {
6 | return sizes.map((size) => `${src(image, size)} ${size}w`).join(', ');
7 | }
8 |
9 | export function fmtprice(price: number) {
10 | return `${price},00 Ø`;
11 | }
12 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/.npmrc:
--------------------------------------------------------------------------------
1 | legacy-peer-deps=true
2 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/README.md:
--------------------------------------------------------------------------------
1 | ```bash
2 | npx nx run team-green:build
3 | npx nx run team-blue:build
4 | npx nx run team-red:build
5 | ```
6 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-blue/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": [
3 | [
4 | "@nx/react/babel",
5 | {
6 | "runtime": "automatic"
7 | }
8 | ]
9 | ],
10 | "plugins": []
11 | }
12 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-blue/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:@nx/react", "../../../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | },
9 | {
10 | "files": ["*.ts", "*.tsx"],
11 | "rules": {}
12 | },
13 | {
14 | "files": ["*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ]
18 | }
19 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-blue/jest.config.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | export default {
3 | displayName: 'team-blue',
4 | preset: '../../../../jest.preset.js',
5 | transform: {
6 | '^(?!.*\\.(js|jsx|ts|tsx|css|json)$)': '@nx/react/plugins/jest',
7 | '^.+\\.[tj]sx?$': ['babel-jest', { presets: ['@nx/react/babel'] }],
8 | },
9 | moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
10 | coverageDirectory:
11 | '../../coverage/apps/team-blue',
12 | };
13 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-blue/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "team_blue",
3 | "version": "0.1.0",
4 | "repository": {
5 | "type": "git",
6 | "url": "https://github.com/valorkin/zephyr-mono.git"
7 | },
8 | "private": true
9 | }
10 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-blue/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-blue/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-blue/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | TeamBlue
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-blue/src/main.tsx:
--------------------------------------------------------------------------------
1 | import('./app/app');
2 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-blue/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-blue/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "jsx": "react-jsx",
4 | "allowJs": false,
5 | "esModuleInterop": false,
6 | "allowSyntheticDefaultImports": true,
7 | "strict": true
8 | },
9 | "files": [],
10 | "include": [],
11 | "references": [
12 | {
13 | "path": "./tsconfig.app.json"
14 | },
15 | {
16 | "path": "./tsconfig.spec.json"
17 | }
18 | ],
19 | "extends": "../../tsconfig.json"
20 | }
21 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": [
3 | [
4 | "@nx/react/babel",
5 | {
6 | "runtime": "automatic"
7 | }
8 | ]
9 | ],
10 | "plugins": []
11 | }
12 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:@nx/react", "../../../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | },
9 | {
10 | "files": ["*.ts", "*.tsx"],
11 | "rules": {}
12 | },
13 | {
14 | "files": ["*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ]
18 | }
19 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/jest.config.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | export default {
3 | displayName: 'team-green',
4 | preset: '../../../../jest.preset.js',
5 | transform: {
6 | '^(?!.*\\.(js|jsx|ts|tsx|css|json)$)': '@nx/react/plugins/jest',
7 | '^.+\\.[tj]sx?$': ['babel-jest', { presets: ['@nx/react/babel'] }],
8 | },
9 | moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
10 | coverageDirectory:
11 | '../../coverage/apps/team-green',
12 | };
13 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "team_green",
3 | "version": "0.1.0",
4 | "repository": {
5 | "type": "git",
6 | "url": "https://github.com/valorkin/zephyr-mono.git"
7 | },
8 | "private": true
9 | }
10 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_1.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_2.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_3.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_4.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_4.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_5.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_5.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_6.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_6.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_7.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_7.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_8.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_8.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_9.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/assets/team-green/images/reco_9.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-green/src/favicon.ico
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | TeamGreen
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/main.tsx:
--------------------------------------------------------------------------------
1 | import('./app/app');
2 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-green/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "jsx": "react-jsx",
4 | "allowJs": false,
5 | "esModuleInterop": false,
6 | "allowSyntheticDefaultImports": true,
7 | "strict": true
8 | },
9 | "files": [],
10 | "include": [],
11 | "references": [
12 | {
13 | "path": "./tsconfig.app.json"
14 | },
15 | {
16 | "path": "./tsconfig.spec.json"
17 | }
18 | ],
19 | "extends": "../../tsconfig.json"
20 | }
21 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": [
3 | [
4 | "@nx/react/babel",
5 | {
6 | "runtime": "automatic"
7 | }
8 | ]
9 | ],
10 | "plugins": []
11 | }
12 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["plugin:@nx/react", "../../../../.eslintrc.json"],
3 | "ignorePatterns": ["!**/*"],
4 | "overrides": [
5 | {
6 | "files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
7 | "rules": {}
8 | },
9 | {
10 | "files": ["*.ts", "*.tsx"],
11 | "rules": {}
12 | },
13 | {
14 | "files": ["*.js", "*.jsx"],
15 | "rules": {}
16 | }
17 | ]
18 | }
19 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/@mf-types/team_blue/BlueBasket.d.ts:
--------------------------------------------------------------------------------
1 | export * from './compiled-types/apps/team-blue/src/app/team-blue-basket';
2 | export { default } from './compiled-types/apps/team-blue/src/app/team-blue-basket';
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/@mf-types/team_blue/BlueBuy.d.ts:
--------------------------------------------------------------------------------
1 | export * from './compiled-types/apps/team-blue/src/app/team-blue-buy';
2 | export { default } from './compiled-types/apps/team-blue/src/app/team-blue-buy';
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/@mf-types/team_blue/apis.d.ts:
--------------------------------------------------------------------------------
1 |
2 | export type RemoteKeys = 'team_blue/BlueBasket' | 'team_blue/BlueBuy';
3 | type PackageType = T extends 'team_blue/BlueBuy' ? typeof import('team_blue/BlueBuy') :T extends 'team_blue/BlueBasket' ? typeof import('team_blue/BlueBasket') :any;
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/@mf-types/team_blue/compiled-types/apps/team-blue/src/app/team-blue-basket.d.ts:
--------------------------------------------------------------------------------
1 | export default function BlueBasket({ id }: {
2 | id: string;
3 | }): import("react/jsx-runtime").JSX.Element;
4 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/@mf-types/team_blue/compiled-types/apps/team-blue/src/app/team-blue-buy.d.ts:
--------------------------------------------------------------------------------
1 | export default function BlueBuy({ id, sku }: {
2 | id: string;
3 | sku: string;
4 | }): import("react/jsx-runtime").JSX.Element;
5 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/@mf-types/team_green/GreenRecos.d.ts:
--------------------------------------------------------------------------------
1 | export * from './compiled-types/apps/team-green/src/app/team-green-recos';
2 | export { default } from './compiled-types/apps/team-green/src/app/team-green-recos';
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/@mf-types/team_green/apis.d.ts:
--------------------------------------------------------------------------------
1 |
2 | export type RemoteKeys = 'team_green/GreenRecos';
3 | type PackageType = T extends 'team_green/GreenRecos' ? typeof import('team_green/GreenRecos') :any;
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/@mf-types/team_green/compiled-types/apps/team-green/src/app/team-green-recos.d.ts:
--------------------------------------------------------------------------------
1 | export default function GreenRecos({ id, sku }: {
2 | id: string;
3 | sku: string;
4 | }): import("react/jsx-runtime").JSX.Element;
5 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/jest.config.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | export default {
3 | displayName: 'team-red',
4 | preset: '../../../../jest.preset.js',
5 | transform: {
6 | '^(?!.*\\.(js|jsx|ts|tsx|css|json)$)': '@nx/react/plugins/jest',
7 | '^.+\\.[tj]sx?$': ['babel-jest', { presets: ['@nx/react/babel'] }],
8 | },
9 | moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
10 | coverageDirectory:
11 | '../../coverage/apps/team-red',
12 | };
13 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "team_red",
3 | "version": "0.1.0",
4 | "repository": {
5 | "type": "git",
6 | "url": "https://github.com/valorkin/zephyr-mono.git"
7 | },
8 | "scripts": {
9 | "build": "nx run team_red:build --skip-nx-cache"
10 | },
11 | "private": true
12 | }
13 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_1.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_2.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_3.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_4.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_4.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_5.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_5.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_6.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_6.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_7.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_7.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_8.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_8.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_9.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-green/images/reco_9.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-blue-thumb.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-blue-thumb.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-blue.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-blue.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-green-thumb.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-green-thumb.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-green.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-green.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-red-thumb.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-red-thumb.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-red.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/assets/team-red/images/tractor-red.jpg
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-tractor-sample/apps/team-red/src/favicon.ico
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | TeamRed
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/examples/react-tractor-sample/apps/team-red/src/main.tsx:
--------------------------------------------------------------------------------
1 | import('./app/app');
2 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/.gitignore:
--------------------------------------------------------------------------------
1 | vite.config.ts.timestamp-*
--------------------------------------------------------------------------------
/examples/react-vite-mf/host/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | dist-ssr
13 | *.local
14 |
15 | # Editor directories and files
16 | .vscode/*
17 | !.vscode/extensions.json
18 | .idea
19 | .DS_Store
20 | *.suo
21 | *.ntvs*
22 | *.njsproj
23 | *.sln
24 | *.sw?
25 | .__mf_temp/**
26 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/host/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite + React + TS
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/host/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './App.tsx';
4 | import './index.css';
5 |
6 | createRoot(document.getElementById('root')!).render(
7 |
8 |
9 |
10 | );
11 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/host/src/main.tsx:
--------------------------------------------------------------------------------
1 | import { init } from '@module-federation/runtime';
2 |
3 | init({
4 | name: 'vite-host',
5 | remotes: [],
6 | });
7 |
8 | import('./bootstrap');
9 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/host/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/host/tsconfig.app.tsbuildinfo:
--------------------------------------------------------------------------------
1 | {"root":["./src/app.tsx","./src/bootstrap.tsx","./src/main.tsx","./src/vite-env.d.ts"],"version":"5.8.2"}
--------------------------------------------------------------------------------
/examples/react-vite-mf/host/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [{ "path": "./tsconfig.app.json" }, { "path": "./tsconfig.node.json" }]
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/host/tsconfig.node.tsbuildinfo:
--------------------------------------------------------------------------------
1 | {"root":["./vite.config.ts"],"version":"5.8.2"}
--------------------------------------------------------------------------------
/examples/react-vite-mf/image.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-vite-mf/image.png
--------------------------------------------------------------------------------
/examples/react-vite-mf/remote/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | dist-ssr
13 | *.local
14 |
15 | # Editor directories and files
16 | .vscode/*
17 | !.vscode/extensions.json
18 | .idea
19 | .DS_Store
20 | *.suo
21 | *.ntvs*
22 | *.njsproj
23 | *.sln
24 | *.sw?
25 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/remote/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite + React + TS
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/remote/src/Button.css:
--------------------------------------------------------------------------------
1 | .card-border {
2 | border: 1px dashed red;
3 | padding: 0.8rem;
4 | border-radius: 20px;
5 | }
6 |
7 | .card {
8 | padding: 2em;
9 | }
10 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/remote/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './App.tsx';
4 | import './index.css';
5 |
6 | createRoot(document.getElementById('root')!).render(
7 |
8 |
9 |
10 | );
11 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/remote/src/main.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './App.tsx';
4 | import './index.css';
5 |
6 | createRoot(document.getElementById('root')!).render(
7 |
8 |
9 |
10 | );
11 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/remote/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/remote/tsconfig.app.tsbuildinfo:
--------------------------------------------------------------------------------
1 | {"root":["./src/app.tsx","./src/button.tsx","./src/bootstrap.tsx","./src/main.tsx","./src/vite-env.d.ts"],"version":"5.8.2"}
--------------------------------------------------------------------------------
/examples/react-vite-mf/remote/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [{ "path": "./tsconfig.app.json" }, { "path": "./tsconfig.node.json" }]
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/remote/tsconfig.node.tsbuildinfo:
--------------------------------------------------------------------------------
1 | {"root":["./vite.config.ts"],"version":"5.8.2"}
--------------------------------------------------------------------------------
/examples/react-vite-mf/rspack/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": ["@babel/preset-typescript", "@babel/preset-react", "@babel/preset-env"],
3 | "plugins": [
4 | ["@babel/transform-runtime"]
5 | ]
6 | }
7 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/rspack/postcss.config.js:
--------------------------------------------------------------------------------
1 | const autoprefixer = require('autoprefixer');
2 | const tailwindcss = require('tailwindcss');
3 |
4 | module.exports = {
5 | plugins: [tailwindcss, autoprefixer],
6 | };
7 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/rspack/src/assets/rspack-logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-vite-mf/rspack/src/assets/rspack-logo.png
--------------------------------------------------------------------------------
/examples/react-vite-mf/rspack/src/global.d.ts:
--------------------------------------------------------------------------------
1 | declare module '*.png' {
2 | const value: string;
3 | export default value;
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/rspack/src/index.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
5 | body {
6 | font-family: Arial, Helvetica, sans-serif;
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/rspack/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | rspack
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/rspack/src/index.tsx:
--------------------------------------------------------------------------------
1 | import('./App');
2 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/rspack/tailwind.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | content: ['./src/**/*.{js,jsx,ts,tsx}'],
3 | darkMode: false, // or 'media' or 'class'
4 | theme: {
5 | extend: {},
6 | },
7 | variants: {
8 | extend: {},
9 | },
10 | plugins: [],
11 | };
12 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/webpack/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": [
3 | ["@babel/preset-env"],
4 | "@babel/preset-typescript",
5 | [
6 | "@babel/preset-react",
7 | {
8 | "runtime": "automatic" // Enables the new JSX transform in React 17+
9 | }
10 | ]
11 | ],
12 | "plugins": ["@babel/plugin-transform-runtime", "@babel/plugin-syntax-dynamic-import"]
13 | }
14 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/webpack/postcss.config.js:
--------------------------------------------------------------------------------
1 | const autoprefixer = require('autoprefixer');
2 | const tailwindcss = require('tailwindcss');
3 |
4 | module.exports = {
5 | plugins: [tailwindcss, autoprefixer],
6 | };
7 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/webpack/src/assets/webpack-logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-vite-mf/webpack/src/assets/webpack-logo.png
--------------------------------------------------------------------------------
/examples/react-vite-mf/webpack/src/global.d.ts:
--------------------------------------------------------------------------------
1 | declare module '*.png' {
2 | const value: string;
3 | export default value;
4 | }
5 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/webpack/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | webpack
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/webpack/src/index.scss:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
5 | body {
6 | font-family: Arial, Helvetica, sans-serif;
7 | }
8 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/webpack/src/index.ts:
--------------------------------------------------------------------------------
1 | import('./App');
2 |
--------------------------------------------------------------------------------
/examples/react-vite-mf/webpack/tailwind.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | content: ['./src/**/*.{js,jsx,ts,tsx}'],
3 | darkMode: false, // or 'media' or 'class'
4 | theme: {
5 | extend: {},
6 | },
7 | variants: {
8 | extend: {},
9 | },
10 | plugins: [],
11 | };
12 |
--------------------------------------------------------------------------------
/examples/react-vite-nx/.prettierignore:
--------------------------------------------------------------------------------
1 | # Add files here to ignore them from prettier formatting
2 | /dist
3 | /coverage
4 | /.nx/cache
5 | /.nx/workspace-data
--------------------------------------------------------------------------------
/examples/react-vite-nx/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "singleQuote": true
3 | }
4 |
--------------------------------------------------------------------------------
/examples/react-vite-nx/project.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-vite-nx",
3 | "$schema": "node_modules/nx/schemas/project-schema.json",
4 | "includedScripts": [],
5 | "sourceRoot": "./src",
6 | "projectType": "application",
7 | "tags": [],
8 | "// targets": "to see all targets run: nx show project react-vite-nx --web",
9 | "targets": {}
10 | }
11 |
--------------------------------------------------------------------------------
/examples/react-vite-nx/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-vite-nx/public/favicon.ico
--------------------------------------------------------------------------------
/examples/react-vite-nx/src/app/app.module.css:
--------------------------------------------------------------------------------
1 | /* Your styles goes here. */
2 |
--------------------------------------------------------------------------------
/examples/react-vite-nx/src/app/app.spec.tsx:
--------------------------------------------------------------------------------
1 | import { render } from '@testing-library/react';
2 |
3 | import App from './app';
4 |
5 | describe('App', () => {
6 | it('should render successfully', () => {
7 | const { baseElement } = render();
8 | expect(baseElement).toBeTruthy();
9 | });
10 |
11 | it('should have a greeting as the title', () => {
12 | const { getByText } = render();
13 | expect(getByText(/Welcome react-vite-nx/gi)).toBeTruthy();
14 | });
15 | });
16 |
--------------------------------------------------------------------------------
/examples/react-vite-nx/src/app/app.tsx:
--------------------------------------------------------------------------------
1 | // eslint-disable-next-line @typescript-eslint/no-unused-vars
2 | import styles from './app.module.css';
3 | import NxWelcome from './nx-welcome';
4 |
5 | export function App() {
6 | return (
7 |
8 |
9 |
10 | );
11 | }
12 |
13 | export default App;
14 |
--------------------------------------------------------------------------------
/examples/react-vite-nx/src/assets/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/react-vite-nx/src/assets/.gitkeep
--------------------------------------------------------------------------------
/examples/react-vite-nx/src/main.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import * as ReactDOM from 'react-dom/client';
3 | import App from './app/app';
4 |
5 | const root = ReactDOM.createRoot(
6 | document.getElementById('root') as HTMLElement
7 | );
8 |
9 | root.render(
10 |
11 |
12 |
13 | );
14 |
--------------------------------------------------------------------------------
/examples/react-vite-nx/src/styles.css:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
--------------------------------------------------------------------------------
/examples/react-vite-ts/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | .vite-inspect
13 | dist-ssr
14 | *.local
15 |
16 | # Editor directories and files
17 | .vscode/*
18 | !.vscode/extensions.json
19 | .idea
20 | .DS_Store
21 | *.suo
22 | *.ntvs*
23 | *.njsproj
24 | *.sln
25 | *.sw?
26 |
--------------------------------------------------------------------------------
/examples/react-vite-ts/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite + React + TS
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/react-vite-ts/src/main.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import App from './App.tsx';
4 | import './index.css';
5 |
6 | ReactDOM.createRoot(document.getElementById('root')!).render(
7 |
8 |
9 |
10 | );
11 |
--------------------------------------------------------------------------------
/examples/react-vite-ts/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/react-vite-ts/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "composite": true,
4 | "skipLibCheck": true,
5 | "module": "ESNext",
6 | "moduleResolution": "bundler",
7 | "allowSyntheticDefaultImports": true,
8 | "strict": true
9 | },
10 | "include": [
11 | "vite.config"
12 | ]
13 | }
14 |
--------------------------------------------------------------------------------
/examples/react-vite-ts/vite.config.ts:
--------------------------------------------------------------------------------
1 | import {defineConfig} from 'vite';
2 | import react from '@vitejs/plugin-react';
3 | import {withZephyr} from 'vite-plugin-zephyr';
4 | import Inspect from 'vite-plugin-inspect';
5 |
6 | // https://vitejs.dev/config/
7 | export default defineConfig({
8 | plugins: [
9 | react(),
10 | Inspect({ build: true, outputDir: 'dist/.vite-inspect' }),
11 | withZephyr(),
12 | ],
13 | });
14 |
--------------------------------------------------------------------------------
/examples/rolldown-react/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "rolldown-react",
3 | "version": "1.0.0",
4 | "private": true,
5 | "scripts": {
6 | "build": "rolldown --config ./rolldown.config.mjs"
7 | },
8 | "dependencies": {
9 | "react": "^19.0.0",
10 | "react-dom": "^19.0.0"
11 | },
12 | "devDependencies": {
13 | "@types/react": "^19.0.8",
14 | "@types/react-dom": "^19.0.3",
15 | "rolldown": "1.0.0-beta.3",
16 | "zephyr-rolldown-plugin": "catalog:zephyr"
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/examples/rolldown-react/src/main.tsx:
--------------------------------------------------------------------------------
1 | import { StrictMode } from 'react';
2 | import { createRoot } from 'react-dom/client';
3 | import App from './App';
4 |
5 | createRoot(document.getElementById('root')!).render(
6 |
7 |
8 |
9 | );
10 |
--------------------------------------------------------------------------------
/examples/rspack-project/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | dist-ssr
13 | *.local
14 |
15 | # Editor directories and files
16 | .vscode/*
17 | !.vscode/extensions.json
18 | .idea
19 | .DS_Store
20 | *.suo
21 | *.ntvs*
22 | *.njsproj
23 | *.sln
24 | *.sw?
25 |
--------------------------------------------------------------------------------
/examples/rspack-project/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | Rspack + React
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/examples/rspack-project/src/main.jsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import ReactDOM from 'react-dom/client'
3 | import App from './App'
4 | import './index.css'
5 |
6 | ReactDOM.createRoot(document.getElementById('root')).render(
7 |
8 |
9 |
10 | )
11 |
--------------------------------------------------------------------------------
/examples/solid/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | dist-ssr
13 | *.local
14 |
15 | # Editor directories and files
16 | .vscode/*
17 | !.vscode/extensions.json
18 | .idea
19 | .DS_Store
20 | *.suo
21 | *.ntvs*
22 | *.njsproj
23 | *.sln
24 | *.sw?
25 |
--------------------------------------------------------------------------------
/examples/solid/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite + Solid + TS
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/solid/src/App.css:
--------------------------------------------------------------------------------
1 | #root {
2 | max-width: 1280px;
3 | margin: 0 auto;
4 | padding: 2rem;
5 | text-align: center;
6 | }
7 |
8 | .logo {
9 | height: 6em;
10 | padding: 1.5em;
11 | will-change: filter;
12 | transition: filter 300ms;
13 | }
14 | .logo:hover {
15 | filter: drop-shadow(0 0 2em #646cffaa);
16 | }
17 | .logo.solid:hover {
18 | filter: drop-shadow(0 0 2em #61dafbaa);
19 | }
20 |
21 | .card {
22 | padding: 2em;
23 | }
24 |
25 | .read-the-docs {
26 | color: #888;
27 | }
28 |
--------------------------------------------------------------------------------
/examples/solid/src/index.tsx:
--------------------------------------------------------------------------------
1 | /* @refresh reload */
2 | import { render } from 'solid-js/web'
3 | import './index.css'
4 | import App from './App.tsx'
5 |
6 | const root = document.getElementById('root')
7 |
8 | render(() => , root!)
9 |
--------------------------------------------------------------------------------
/examples/solid/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/solid/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [
4 | { "path": "./tsconfig.app.json" },
5 | { "path": "./tsconfig.node.json" }
6 | ]
7 | }
8 |
--------------------------------------------------------------------------------
/examples/solid/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from "vite";
2 | import solid from "vite-plugin-solid";
3 | import { withZephyr } from "vite-plugin-zephyr";
4 |
5 | export default defineConfig({
6 | plugins: [solid(), withZephyr()],
7 | });
8 |
--------------------------------------------------------------------------------
/examples/svelte/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | dist-ssr
13 | *.local
14 |
15 | # Editor directories and files
16 | .vscode/*
17 | !.vscode/extensions.json
18 | .idea
19 | .DS_Store
20 | *.suo
21 | *.ntvs*
22 | *.njsproj
23 | *.sln
24 | *.sw?
25 |
--------------------------------------------------------------------------------
/examples/svelte/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite + Svelte + TS
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/svelte/src/lib/Counter.svelte:
--------------------------------------------------------------------------------
1 |
7 |
8 |
11 |
--------------------------------------------------------------------------------
/examples/svelte/src/main.ts:
--------------------------------------------------------------------------------
1 | import { mount } from 'svelte'
2 | import './app.css'
3 | import App from './App.svelte'
4 |
5 | const app = mount(App, {
6 | target: document.getElementById('app')!,
7 | })
8 |
9 | export default app
10 |
--------------------------------------------------------------------------------
/examples/svelte/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 | ///
3 |
--------------------------------------------------------------------------------
/examples/svelte/svelte.config.js:
--------------------------------------------------------------------------------
1 | import { vitePreprocess } from '@sveltejs/vite-plugin-svelte'
2 |
3 | export default {
4 | // Consult https://svelte.dev/docs#compile-time-svelte-preprocess
5 | // for more information about preprocessors
6 | preprocess: vitePreprocess(),
7 | }
8 |
--------------------------------------------------------------------------------
/examples/svelte/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [
4 | { "path": "./tsconfig.app.json" },
5 | { "path": "./tsconfig.node.json" }
6 | ]
7 | }
8 |
--------------------------------------------------------------------------------
/examples/svelte/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from 'vite';
2 | import { svelte } from '@sveltejs/vite-plugin-svelte';
3 | import { withZephyr } from 'vite-plugin-zephyr';
4 |
5 | // https://vite.dev/config/
6 | export default defineConfig({
7 | plugins: [svelte(), withZephyr()],
8 | });
9 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/.npmrc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/examples/turbo-rspack-mf/.npmrc
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/.gitignore:
--------------------------------------------------------------------------------
1 | # Local
2 | .DS_Store
3 | *.local
4 | *.log*
5 |
6 | # Dist
7 | node_modules
8 | dist/
9 |
10 | # IDE
11 | .vscode/*
12 | !.vscode/extensions.json
13 | .idea
14 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/README.md:
--------------------------------------------------------------------------------
1 | # Rspack Project
2 |
3 | ## Setup
4 |
5 | Install the dependencies:
6 |
7 | ```bash
8 | npm install
9 | ```
10 |
11 | ## Get Started
12 |
13 | Start the dev server:
14 |
15 | ```bash
16 | npm run dev
17 | ```
18 |
19 | Build the app for production:
20 |
21 | ```bash
22 | npm run build
23 | ```
24 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Rspack + React + TS
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/module-federation.config.ts:
--------------------------------------------------------------------------------
1 | import type { ModuleFederationPluginOptions } from "@rspack/core";
2 |
3 | export const mfConfig: ModuleFederationPluginOptions = {
4 | name: "home",
5 | filename: "remoteEntry.js",
6 | exposes: {
7 | "./RemoteEntry": "./src/RemoteEntry.tsx"
8 | },
9 | remotes: {
10 | host: "host@http://localhost:3000/remoteEntry.js"
11 | },
12 | shared: ["react", "react-dom", "react-router"]
13 | };
14 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/postcss.config.mjs:
--------------------------------------------------------------------------------
1 | export default {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | }
7 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/src/bootstrap.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
5 | :root {
6 | @apply h-[100vh] bg-black;
7 | }
8 | body {
9 | @apply h-full;
10 | }
11 | #root {
12 | @apply h-full;
13 | }
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import React from "react";
2 | import ReactDOM from "react-dom/client";
3 | import Host from 'host/RemoteEntry';
4 | import "./bootstrap.css";
5 |
6 | ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
7 |
8 |
9 | ,
10 | );
11 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/src/main.tsx:
--------------------------------------------------------------------------------
1 | import("./bootstrap");
2 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/tailwind.config.ts:
--------------------------------------------------------------------------------
1 | // tailwind config is required for editor support
2 |
3 | import type { Config } from "tailwindcss";
4 | import sharedConfig from "@repo/tailwind-config";
5 |
6 | const config: Pick = {
7 | content: [
8 | "./src/**/*.{js,ts,jsx,tsx}",
9 | "../settings/src/**/*.{js,ts,jsx,tsx}",
10 | "../host/src/**/*.{js,ts,jsx,tsx}"
11 | ],
12 | presets: [sharedConfig]
13 | };
14 |
15 | export default config;
16 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/home/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@repo/typescript-config/mf-tsconfig.json",
3 | "include": ["src"],
4 | "ts-node": {
5 | "compilerOptions": {
6 | "module": "CommonJS"
7 | }
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/.gitignore:
--------------------------------------------------------------------------------
1 | # Local
2 | .DS_Store
3 | *.local
4 | *.log*
5 |
6 | # Dist
7 | node_modules
8 | dist/
9 |
10 | # IDE
11 | .vscode/*
12 | !.vscode/extensions.json
13 | .idea
14 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/README.md:
--------------------------------------------------------------------------------
1 | # Rspack Project
2 |
3 | ## Setup
4 |
5 | Install the dependencies:
6 |
7 | ```bash
8 | npm install
9 | ```
10 |
11 | ## Get Started
12 |
13 | Start the dev server:
14 |
15 | ```bash
16 | npm run dev
17 | ```
18 |
19 | Build the app for production:
20 |
21 | ```bash
22 | npm run build
23 | ```
24 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Rspack + React + TS
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/postcss.config.mjs:
--------------------------------------------------------------------------------
1 | export default {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | }
7 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/src/bootstrap.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
5 | :root {
6 | @apply h-[100vh] bg-black;
7 | }
8 | body {
9 | @apply h-full;
10 | }
11 | #root {
12 | @apply h-full;
13 | }
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import './bootstrap.css';
4 | import App from './App';
5 |
6 | ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
7 |
8 |
9 | ,
10 | );
11 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/src/main.tsx:
--------------------------------------------------------------------------------
1 | import("./bootstrap");
2 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/tailwind.config.ts:
--------------------------------------------------------------------------------
1 | // tailwind config is required for editor support
2 |
3 | import type { Config } from "tailwindcss";
4 | import sharedConfig from "@repo/tailwind-config";
5 |
6 | const config: Pick = {
7 | content: [
8 | "./src/**/*.{js,ts,jsx,tsx}",
9 | "../settings/src/**/*.{js,ts,jsx,tsx}",
10 | "../home/src/**/*.{js,ts,jsx,tsx}"
11 | ],
12 | presets: [sharedConfig]
13 | };
14 |
15 | export default config;
16 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@repo/typescript-config/mf-tsconfig.json",
3 | "include": ["src"],
4 | "ts-node": {
5 | "compilerOptions": {
6 | "module": "CommonJS"
7 | }
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/host/turbo.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://turbo.build/schema.json",
3 | "extends": ["//"],
4 | "tasks": {
5 | "build": {
6 | "dependsOn": ["settings#build", "home#build"],
7 | "inputs": ["$TURBO_DEFAULT$", ".env*"],
8 | "outputs": [".next/**", "!.next/cache/**"]
9 | }
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/.gitignore:
--------------------------------------------------------------------------------
1 | # Local
2 | .DS_Store
3 | *.local
4 | *.log*
5 |
6 | # Dist
7 | node_modules
8 | dist/
9 |
10 | # IDE
11 | .vscode/*
12 | !.vscode/extensions.json
13 | .idea
14 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/README.md:
--------------------------------------------------------------------------------
1 | # Rspack Project
2 |
3 | ## Setup
4 |
5 | Install the dependencies:
6 |
7 | ```bash
8 | npm install
9 | ```
10 |
11 | ## Get Started
12 |
13 | Start the dev server:
14 |
15 | ```bash
16 | npm run dev
17 | ```
18 |
19 | Build the app for production:
20 |
21 | ```bash
22 | npm run build
23 | ```
24 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Rspack + React + TS
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/module-federation.config.ts:
--------------------------------------------------------------------------------
1 | import type { ModuleFederationPluginOptions } from "@rspack/core";
2 |
3 | export const mfConfig: ModuleFederationPluginOptions = {
4 | name: "settings",
5 | filename: "remoteEntry.js",
6 | exposes: {
7 | "./RemoteEntry": "./src/RemoteEntry.tsx"
8 | },
9 | remotes: {
10 | host: "host@http://localhost:3000/remoteEntry.js"
11 | },
12 | shared: ["react", "react-dom", "react-router"]
13 | };
14 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/postcss.config.mjs:
--------------------------------------------------------------------------------
1 | export default {
2 | plugins: {
3 | tailwindcss: {},
4 | autoprefixer: {},
5 | },
6 | }
7 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/src/bootstrap.css:
--------------------------------------------------------------------------------
1 | @tailwind base;
2 | @tailwind components;
3 | @tailwind utilities;
4 |
5 | :root {
6 | @apply h-[100vh] bg-black;
7 | }
8 | body {
9 | @apply h-full;
10 | }
11 | #root {
12 | @apply h-full;
13 | }
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/src/bootstrap.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom/client';
3 | import Host from 'host/RemoteEntry';
4 | import './bootstrap.css';
5 |
6 | ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
7 |
8 |
9 | ,
10 | );
11 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/src/main.tsx:
--------------------------------------------------------------------------------
1 | import("./bootstrap");
2 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/tailwind.config.ts:
--------------------------------------------------------------------------------
1 | // tailwind config is required for editor support
2 |
3 | import type { Config } from "tailwindcss";
4 | import sharedConfig from "@repo/tailwind-config";
5 |
6 | const config: Pick = {
7 | content: [
8 | "./src/**/*.{js,ts,jsx,tsx}",
9 | "../home/src/**/*.{js,ts,jsx,tsx}",
10 | "../host/src/**/*.{js,ts,jsx,tsx}"
11 | ],
12 | presets: [sharedConfig]
13 | };
14 |
15 | export default config;
16 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/apps/settings/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@repo/typescript-config/mf-tsconfig.json",
3 | "include": ["src"],
4 | "ts-node": {
5 | "compilerOptions": {
6 | "module": "CommonJS"
7 | }
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "ze-starter-turbo",
3 | "private": true,
4 | "scripts": {
5 | "build": "turbo build",
6 | "check": "biome check --write",
7 | "dev": "turbo dev",
8 | "format": "biome format --write",
9 | "lint": "turbo lint"
10 | },
11 | "packageManager": "pnpm@10.6.3",
12 | "devDependencies": {
13 | "@biomejs/biome": "catalog:biome",
14 | "turbo": "catalog:turbo",
15 | "typescript": "catalog:typescript"
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/config-tailwind/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "@repo/tailwind-config",
3 | "version": "0.0.0",
4 | "private": true,
5 | "exports": {
6 | ".": "./tailwind.config.ts"
7 | },
8 | "devDependencies": {
9 | "@repo/typescript-config": "workspace:*",
10 | "tailwindcss": "catalog:tailwind3"
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/config-tailwind/tailwind.config.ts:
--------------------------------------------------------------------------------
1 | import type { Config } from "tailwindcss";
2 |
3 | // We want each package to be responsible for its own content.
4 | const config: Omit = {
5 | theme: {
6 | extend: {
7 | backgroundImage: {
8 | "glow-conic":
9 | "conic-gradient(from 180deg at 50% 50%, #2a8af6 0deg, #a853ba 180deg, #e92a67 360deg)"
10 | }
11 | }
12 | },
13 | plugins: []
14 | };
15 | export default config;
16 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/config-tailwind/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@repo/typescript-config/base.json",
3 | "include": ["."],
4 | "exclude": ["dist", "build", "node_modules"]
5 | }
6 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/typescript-config/mf-tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://json.schemastore.org/tsconfig",
3 | "extends": "./base.json",
4 | "compilerOptions": {
5 | "paths": {
6 | "host/RemoteEntry": ["../../apps/host/src/App.tsx"],
7 | "home/RemoteEntry": ["../../apps/home/src/RemoteEntry.tsx"],
8 | "settings/RemoteEntry": ["../../apps/settings/src/RemoteEntry.tsx"]
9 | }
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/typescript-config/nextjs.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://json.schemastore.org/tsconfig",
3 | "extends": "./base.json",
4 | "compilerOptions": {
5 | "plugins": [{ "name": "next" }],
6 | "module": "ESNext",
7 | "moduleResolution": "Bundler",
8 | "allowJs": true,
9 | "jsx": "preserve",
10 | "noEmit": true
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/typescript-config/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "@repo/typescript-config",
3 | "version": "0.0.0",
4 | "private": true,
5 | "license": "MIT",
6 | "publishConfig": {
7 | "access": "public"
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/typescript-config/react-library.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://json.schemastore.org/tsconfig",
3 | "extends": "./base.json",
4 | "compilerOptions": {
5 | "jsx": "react-jsx"
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/ui/src/code.tsx:
--------------------------------------------------------------------------------
1 | import type { JSX } from 'react';
2 |
3 | export function Code({
4 | children,
5 | className,
6 | }: {
7 | children: React.ReactNode;
8 | className?: string;
9 | }): JSX.Element {
10 | return {children}
;
11 | }
12 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/ui/src/header.tsx:
--------------------------------------------------------------------------------
1 | export function Header() {
2 | return (
3 |
4 |
Header
5 |
6 | );
7 | }
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/ui/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@repo/typescript-config/react-library.json",
3 | "compilerOptions": {
4 | "outDir": "dist"
5 | },
6 | "include": ["src"],
7 | "exclude": ["node_modules", "dist"]
8 | }
9 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/ui/tsconfig.lint.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@repo/typescript-config/react-library.json",
3 | "compilerOptions": {
4 | "outDir": "dist"
5 | },
6 | "include": ["src", "turbo"],
7 | "exclude": ["node_modules", "dist"]
8 | }
9 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/packages/ui/turbo/generators/templates/component.hbs:
--------------------------------------------------------------------------------
1 | export const {{ pascalCase name }} = ({ children }: { children: React.ReactNode }) => {
2 | return (
3 |
4 |
{{ pascalCase name }} Component
5 | {children}
6 |
7 | );
8 | };
9 |
--------------------------------------------------------------------------------
/examples/turbo-rspack-mf/pnpm-workspace.yaml:
--------------------------------------------------------------------------------
1 | packages:
2 | - "apps/*"
3 | - "packages/*"
4 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "zephyr-examples",
3 | "version": "0.0.1",
4 | "license": "Apache-2.0",
5 | "packageManager": "pnpm@10.6.3",
6 | "scripts": {
7 | "remove-all-node-modules": "find . -name 'node_modules' -type d -prune -exec rm -rf '{}' + ",
8 | "remove-all-dist": "find . -name 'dist' -type d -prune -exec rm -rf '{}' + ",
9 | "run-sherif": "pnpm dlx sherif@latest"
10 | },
11 | "private": true,
12 | "devDependencies": {
13 | "process": "^0.11.10"
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/scripts/.gitignore:
--------------------------------------------------------------------------------
1 | tmp
2 |
--------------------------------------------------------------------------------
/scripts/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "zephyr-examples-scripts",
3 | "type": "commonjs",
4 | "scripts": {
5 | "upgrade-plugins": "node ./src/upgrade-plugins.js",
6 | "build-packages": "node ./src/build-packages.js"
7 | },
8 | "devDependencies": {
9 | "@types/node": "^22.10.7",
10 | "@types/node-persist": "^3.1.8"
11 | },
12 | "dependencies": {
13 | "node-persist": "^4.0.4"
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/scripts/src/config.js:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZephyrCloudIO/zephyr-examples/ddaf1f3e597c8b48e606e827471842a96097bcab/scripts/src/config.js
--------------------------------------------------------------------------------