Coder Social home page Coder Social logo

Comments (6)

jjaimealeman avatar jjaimealeman commented on May 22, 2024 2

BTW: just tested the NuxtJS example version, and it works beautifully.

from examples.

rijkvanzanten avatar rijkvanzanten commented on May 22, 2024 1

That's true! Actually it initially stemmed from we weren't providing the local directus instance so it may not be localhost:8055, hence the attempt at making it easier to configure via .env files.

Ahh good one, yeah!

from examples.

rijkvanzanten avatar rijkvanzanten commented on May 22, 2024

I haven't tested it locally (yet), but from the codebase it should set the base url for directus to 8055 here:

https://github.com/directus/examples/blob/4c3f0c3a3dc606fbf309fd00f96b7ba792855261/vue/src/services/directus.js#L3

pulled in from the .env here:

https://github.com/directus/examples/blob/4c3f0c3a3dc606fbf309fd00f96b7ba792855261/vue/.env.example#L1

from examples.

rijkvanzanten avatar rijkvanzanten commented on May 22, 2024

@jjaimealeman This seems to work as expected on my end! Did you change the value in .env by any chance?

Steps I took (with the demo Directus instance running):

cd vue
npm install
cp .env.example .env
npm run dev

(That reminds me @azrikahar, we could drop the requirement on the .env files in favor of just hardcoding the example localhost:8080, but i'll leave that up to you 👍🏻 )

from examples.

rijkvanzanten avatar rijkvanzanten commented on May 22, 2024

I'll close this for now, as I believe this works as expected. Lemme know if I'm missing anything @jjaimealeman 🙂

from examples.

azrikahar avatar azrikahar commented on May 22, 2024

This seems to work as expected on my end!

Works on my end as well! I believe it is indeed VITE_DIRECTUS_URL not loading (somehow) for OP since it's showing :3000 in the screenshot instead.

we could drop the requirement on the .env files in favor of just hardcoding the example

That's true! Actually it initially stemmed from we weren't providing the local directus instance so it may not be localhost:8055, hence the attempt at making it easier to configure via .env files. 😄

from examples.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.