Commit Graph
5 Commits
Author SHA1 Message Date
Ivan Starkov 8be665e68d experimental: SSG download support (#3783)
## Description

See corresponding [SaaS
PR](https://github.com/webstudio-is/webstudio-saas/pull/311) too

## Steps for reproduction

Click Publish/Export

<img width="363" alt="image"
src="https://github.com/user-attachments/assets/fbc1f4e5-3a2c-4bb9-9242-025196f991bc">


Deploy zip to netlify
<img width="1710" alt="image"
src="https://github.com/user-attachments/assets/daca4ead-6272-4729-8e82-0986301e5c8b">


## Code Review

- [ ] hi @kof, I need you to do
  - conceptual review (architecture, feature-correctness)
  - detailed review (read every line)
  - test it on preview

## Before requesting a review

- [ ] made a self-review
- [ ] added inline comments where things may be not obvious (the "why",
not "what")

## Before merging

- [ ] tested locally and on preview environment (preview dev login:
5de6)
- [ ] updated [test
cases](https://github.com/webstudio-is/webstudio/blob/main/apps/builder/docs/test-cases.md)
document
- [ ] added tests
- [ ] if any new env variables are added, added them to `.env` file
2024-07-30 08:57:33 +03:00
Bogdan Chadkin a65ab3379f build: forbid unused parameters (#3732)
Enabled flag in tsconfig to forbid unused parameters.
2024-07-15 21:17:13 +02:00
Ivan Starkov 393cc90612 build: Move build time env vars in env.static (#3183)
## Description

This variables are build time and not dependent on deploy. Moreover we
don't know them during production deploy.
But they are used as versioning at saas level 


## Steps for reproduction

1. click button
2. expect xyz

## Code Review

- [ ] hi @kof, I need you to do
  - conceptual review (architecture, feature-correctness)
  - detailed review (read every line)
  - test it on preview

## Before requesting a review

- [ ] made a self-review
- [ ] added inline comments where things may be not obvious (the "why",
not "what")

## Before merging

- [ ] tested locally and on preview environment (preview dev login:
5de6)
- [ ] updated [test
cases](https://github.com/webstudio-is/webstudio/blob/main/apps/builder/docs/test-cases.md)
document
- [ ] added tests
- [ ] if any new env variables are added, added them to `.env.example`
and the `builder/env-check.js` if mandatory
2024-04-17 16:34:46 +03:00
Ivan Starkov 5e439b77e5 Publish tracking (#1726)
## Description

Add `latestBuild` for each entry in publish dialog
Now we are tracking publish stat for each domain. 
This information is needed to show checkboxes in publish design (next
PRs).

2 new Views were created.

To get the latest build by project + domain
To get the latest build for wstd.xx domain

Publish status is shown per domain (as not every domain would be
published each time)

<img width="362" alt="image"
src="https://github.com/webstudio-is/webstudio-builder/assets/5077042/b4e0357a-63f5-47ba-a119-59ef1adf81d2">

During publish all buttons are disabled as per design

<img width="348" alt="image"
src="https://github.com/webstudio-is/webstudio-builder/assets/5077042/94720bd3-4bda-488c-81f7-71ea9ba2d530">

Also added tooltip on publish button (not in design)

<img width="366" alt="image"
src="https://github.com/webstudio-is/webstudio-builder/assets/5077042/c764a785-aea9-487b-a480-642410293ee3">



## Steps for reproduction

1. click button
2. expect xyz

## Code Review

- [ ] hi @kof, I need you to do
  - conceptual review (architecture, feature-correctness)
  - detailed review (read every line)
  - test it on preview

## Before requesting a review

- [ ] made a self-review
- [ ] added inline comments where things may be not obvious (the "why",
not "what")

## Before merging

- [ ] tested locally and on preview environment (preview dev login:
5de6)
- [ ] updated [test
cases](https://github.com/webstudio-is/webstudio-builder/blob/main/apps/builder/docs/test-cases.md)
document
- [ ] added tests
- [ ] if any new env variables are added, added them to `.env.example`
and the `builder/env-check.js` if mandatory
2023-06-09 00:55:24 +04:00
Ivan Starkov dafa7e8b35 Publish by buildId (#1689)
## Description

The idea is to deploy by `buildId` instead of `projectId`.
Every build now can have `deployment` metadata params (currently
`domains` only, but in the future can be any additional metadata, like
vars etc)

Publish is simplified (-2 workers), the same trpc as for other saas api
is used to publish, see `cms.publish`
(also local development is simplified as edge-api at saas works on local
dev perfectly)

isDev and isProd are not needed anymore. Any published build has
`deployment` metadata, and various builds can be active now on different
domains.

Build clone now seriously faster as no parse/serialize steps involved at
all.

Partial index `CREATE UNIQUE INDEX "Build_dev_index" ON "Build"
("projectId") WHERE "deployment" IS NULL;` created so we could be sure
that no more than 1 dev build exists.

createBuild and cloneBuild are now splitted, and seriously simplified

## Steps for reproduction

1. click button
2. expect xyz

## Code Review

- [ ] hi @kof, I need you to do
  - conceptual review (architecture, feature-correctness)
  - detailed review (read every line)
  - test it on preview

## Before requesting a review

- [ ] made a self-review
- [ ] added inline comments where things may be not obvious (the "why",
not "what")

## Before merging

- [ ] tested locally and on preview environment (preview dev login:
5de6)
- [ ] updated [test
cases](https://github.com/webstudio-is/webstudio-builder/blob/main/apps/builder/docs/test-cases.md)
document
- [ ] added tests
- [ ] if any new env variables are added, added them to `.env.example`
and the `builder/env-check.js` if mandatory
2023-05-30 23:44:05 +04:00