farm icon indicating copy to clipboard operation
farm copied to clipboard

preview command adds cross support

Open 289420843 opened this issue 10 months ago • 6 comments

What problem does this feature solve?

cross-domain access to resource files is supported.

What does the proposed API look like?

farm.config add previewServer config

export default defineConfig({
  server: {
    ...
  },
  previewServer:{
    headers: {
      "Access-Control-Allow-Origin": "*",
    },
    ...
  }
}

or reuse server config.

289420843 avatar Apr 08 '24 07:04 289420843

Thanks, this is a good function point. pr welcome

ErKeLost avatar Apr 08 '24 08:04 ErKeLost

@289420843 Hi, why close this issue?

fu050409 avatar Aug 30 '24 06:08 fu050409

We have added future plans for previewServer to this issues https://github.com/farm-fe/farm/issues/1589, and we are also accelerating the pace of reconstructing the node side to improve the stability and diversity of farm

ErKeLost avatar Aug 30 '24 07:08 ErKeLost

@289420843 Hi, why close this issue?

It's been too long without any progress. If there's a plan, feel free to revive it.

289420843 avatar Aug 30 '24 07:08 289420843

I am a frontend newComer. May I try to add it?I am tring to read the document. What is the good way to start?

daju233 avatar Sep 20 '24 19:09 daju233

hi @daju233 Currently, previewServer is being rebuilt. You can contact @fu050409 . he is now responsible for the rebuilt version of previewServer. If you want to contribute or learn other feature, you can take a look at this roadmap https://github.com/farm-fe/farm/issues/1589 contributions are welcome

ErKeLost avatar Sep 21 '24 00:09 ErKeLost