first time using Postgresql to store imageURL in my table. I am unable to have the picture render in my react component. on my component, the imageUrl link populates but not the actual image itself.
I've labeled it as TEXT in SQL so maybe that's the problem(see below).
DROP TABLE IF EXISTS heroes;
CREATE TABLE
IF NOT EXISTS heroes
(
id int GENERATED BY DEFAULT AS IDENTITY PRIMARY KEY,
heroName TEXT,
realName TEXT,
imageUrl TEXT
);
and
INSERT INTO heroes
(heroName, realName,imageUrl)
VALUES
('Batman', 'Bruce Wayne', 'https://i.stack.imgur.com/kPNrE.jpg'),
('Nightwing', 'Richard Grayson', 'https://i.stack.imgur.com/kPNrE.jpg'),
('Red Hood', 'Jason Todd', 'https://i.stack.imgur.com/kPNrE.jpg'),
('Robin', 'Tim Drake', 'https://i.stack.imgur.com/kPNrE.jpg'),
('Batgirl', 'Barbara Gordon', 'https://i.stack.imgur.com/kPNrE.jpg'),
('Orphan', 'Cassandra Cain', 'https://i.stack.imgur.com/kPNrE.jpg'),
('Huntress', 'Helena Bertinelli', 'https://i.stack.imgur.com/kPNrE.jpg');
Expected a picture to actually render instead of seeing the text string https://i.stack.imgur.com/kPNrE.jpg on the webpage.