[SOLVED] Slug does not match pattern "^[a-zA-Z0-9\\-]+$"

I cd into my project directory and run:

➜  myproject-rn git:(master) ✗ exp start
[exp] Making sure project is set up correctly...
-[exp] Warning: Problem in exp.json. See https://docs.expo.io/versions/v16.0.0/guides/configuration.html.
[exp]   - slug does not match pattern "^[a-zA-Z0-9\\-]+$".
[exp] Your project looks good!

My slug is setup like:

{
    "slug": "exp.host/@username/appname",
}

SOLUTION:

Slug property in exp.json should be just the slug. The docs (somewhat) read like you want it setup like above, but you actually want it like the below

{
    "slug": "appname",
}

Then running exp build:xyz will generate the relevant URL (e.g. exp.host/@username/appname)

4 Likes

I agree, I was also confused after reading the docs and had to spent some time of this. After a Google search I can see arcomito and me are not the only ones.

1 Like