Having issues adding a .env file

I’m having issues adding a .env file using the built in SECRETS tab on replit.

Your project link(s)

solution: https://replit.com/@mallovelli/boilerplate-express

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.69 Safari/537.36

Challenge: Use the .env File

Link to the challenge:

You are not sending the response object. You are just assigning a string to an undeclared variable Response.

The syntax is:

res.json({"someKey": "someValue"})

Then, in the /json GET route handler you created in the last challenge, transform the response object’s message to uppercase if process.env.MESSAGE_STYLE equals uppercase . The response object should either be {"message": "Hello json"} or {"message": "HELLO JSON"} , depending on the MESSAGE_STYLE value.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.