Skip to content

Exclude src-tauri from relative devPath #1897

@parker-codes

Description

@parker-codes

Describe the bug
Not tested by me - came from Discord help-triage.

The developer said:

hi. The web side of my app is just hand-written html/css/js. I do not need a local development server. I would like the Tauri/Rust backend to be the server. What should I do when npm run tauri init asks me for the URL of my development server?

I replied that they can put a relative path instead of a dev server location. My example was to put ../, thinking that devs may keep their vanilla assets at the top level.

Noah highlighted that this may cause issues because it would then include /src-tauri. Obviously this can be bypassed if these are placed in a sub level, like /src.

Expected behavior
We should exclude the /src-tauri directory if pointed at the root level.

We could also add a hint in the docs that devs can use a relative path. This question has come up a few times recently.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions