taniarascia.com | 💾 ‎ Personal website running on Gatsby , React , and Node.js | Frontend Framework library
kandi X-RAY | taniarascia.com Summary
kandi X-RAY | taniarascia.com Summary
Tania's personal website running on Gatsby, React, and Node.js. Note: The source for this site was not created to be a template or theme, but for my own use. Feel free to take whatever inspiration from it that you want, but this code was not written with the intention of being cloned and deployed. As such, I do not provide support or guidance for doing that. I recommend using the Gatsby Advanced Starter to set up a blog or an existing theme created for that purpose.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Index the projects .
- Initialize the website .
- Create a post template .
- Create template for the site .
- Page Template Template .
- Page template helper
- Page index of blog
- wow what to know about to happen
taniarascia.com Key Features
taniarascia.com Examples and Code Snippets
Community Discussions
Trending Discussions on taniarascia.com
QUESTION
I would like to have some text next to an element that has a position of relative and children with positions of absolute.
Following Tania Rascia's tutorial I have created 2 crossfading images, it uses position:absolute
to put the images on top of each other, so that they can fading into each other. However, because position:absolute
takes the iamges out of the 'flow' or the page, this means that the text from the page is behind the crossfading images.
I have tried applying display:inline-block
to the parent of the images and the images themselves, but this hasn't changed anything. I am still new to CSS any tips would be helpful.
ANSWER
Answered 2021-Apr-28 at 17:01I resolved this by moving the width
and height
properties off the child images, to the parent container that held the slideshow.
This should be aesthetically the same but help the document understand how large the slideshow is.
QUESTION
I have been recently been working on a node.js api with a postgresql database that stores books. When you go to the route /books it gives me the heroku application error page (here is the api https://node-api-with-books.herokuapp.com/books) and I followed this tutorial to make it https://www.taniarascia.com/node-express-postgresql-heroku/. It is driving me crazy and here is the error it gives when I do:
...ANSWER
Answered 2021-Mar-16 at 07:58After trying with the uploaded repo. I've confirmed the error lies at the following place
config.js
QUESTION
i am trying to make a CRUD app in DRF-Reactjs by following Tania rascia's example
i have successfully implemented add, delete, list view. but i am trying to edit a specific row which is not updating in DRF backend. but the edited row is shown in the frontend list. why it is not updating in django admin list?
in DRF side views.py:
...ANSWER
Answered 2021-Mar-12 at 23:51- Trying to update something should be done in a put request, not a post request. This is a REST API convention, but a discrepancy may have some consequence down the line.
- In this case, the error in your development tools is telling you that one of your components has an onChange/onSubmit etc property that is changing over the course of one mount from null to a function. This is not what's causing your issue, but I suspect it can be fixed by declaring the code in a handleSubmit function and then putting that into your onSubmit.
- I think the error that's actually causing your problem is that the updatedTodo is not being sent to the backend. All that is being sent is the id (second parameter of axios.post). So if you pause the backend during execution, you would see that request.data = the id only, when it should be TodoSerializer's readable fields.
PS:
- You can add a "debugger;" statement in the code after the updateToDo async request error to see what the error actually is (read more on the development tools debugging - browser dependent).
- Don't abuse fragments - in this case, it would make for a more accessibility-friendly experience if you use divs in most of these components. Wouldn't it make more sense if the heading of some content was grouped with the content? https://developers.google.com/web/fundamentals/accessibility/focus/dom-order-matters
QUESTION
I have successfully created an api that stores books on heroku with express and postgresql following this tutorial https://www.taniarascia.com/node-express-postgresql-heroku/ witch everything works fine but I tried to follow the front-end part but it doesn't work.
Here is the api here https://node-api-with-books.herokuapp.com/books
Any help would be appreciated and it would help me if you used the tutorial to help.
...ANSWER
Answered 2021-Mar-06 at 21:16Based on the tutorial you would need an async function to call the api from a front end.
QUESTION
Background: I have looked through the variations on this question and solutions, but I have not found one that applies to my situation. I know I'm most likely overlooking something incredibly obvious, but it's been hours and I can't for the life of me pinpoint what it is. I'm following along with this tutorial but making it my own: https://www.taniarascia.com/create-a-simple-database-app-connecting-to-mysql-with-php/.
What happens: When I click the submit button, nothing happens. I see "not set" displayed on the screen when the page loads and after clicking submit, so I know I'm in my else block, which means $_POST is not being set.
What I expect to happen: I expect to see "not set" on page load, but then once I have filled out the form and clicked submit, I expect to see "set" in my echo statement to indicate that I'm in my if statement and isset($_POST['submit']) is true/successful, followed by "Success" indicating that the try code block was successful, plus the values I entered in the form fields appearing in the database. For now, though, I'd just be happy if I got that first "set" to display.
I have tried: I've tried breaking out the php into a separate file and linking it up to the form via action="thatfile.php", but I get the same result. I've also tried using "get" instead of "post" for the method and $_REQUEST instead of $_POST, but again, same outcome - "not set" displayed, no data in the db.
Here is my code:
...ANSWER
Answered 2020-Sep-09 at 22:26You are closing the form multiple times before the final end of the form
so the submit is not in the form. Remove these:
QUESTION
I'm trying to access data.address.street but when I call data.address.street I get a key undefined error.
when I call data.id, data.name, I have no problems but when trying to access the ones inside the multidimensional arrays(objects) I'm getting errors.
This is what I'm trying to call from: https://jsonplaceholder.typicode.com/users/1
The error I'm getting:
...ANSWER
Answered 2020-Jun-16 at 08:22I created a stackblitz that fetches the user and displays the address, you can cross-verify your code with this.
QUESTION
I have some question.
I had started React tutorial this page. And I created React project by using 'create-react-app' and delete some files (/src/App.js .. etc.). Finally I written code below and running code.
index.html
...ANSWER
Answered 2020-Apr-13 at 07:04If you are using create-react-app
to bootstrap your project then you need to be aware that create-react-app
has a couple of things abstracted, which makes it easy to create a react app without having to bother about scripts, configuration and build tools.
From the Docs, it was stated that for the project to build, these files must exist with exact filenames:
public/index.html
is the page template;
src/index.js
is the JavaScript entry point.
Here's a link to the Getting Started guide, I hope this helps. Good luck!
P.S From your code - index.js
, I can see you still have a reference to index.css
, just wanted to point this out since you said you deleted everything. You might also want to take out the two tags in the index.html file which is referencing an image and the manifest.json file from the
public
folder (if they don't exist anymore)
QUESTION
Slightly afraid of down-votes as this could be seen as a matter of opinion, but it's not clear how or where else to post this on Stack Exchange, so here I go... I certainly think it's a question that adds value here, at least.
I've recently been reading into Javascript's Map datatype (NOT the map() array method). MDN Reference
I've read and followed various tutorials/articles showing the similarities and differences between Maps, Arrays and 'standard' Objects. One unique property of Maps is that you can use any datatype as a key, including an Object.
There are many examples out there, such as this one from Tania Rascia
...ANSWER
Answered 2020-Feb-19 at 10:00From my tweets on the subject:
Say you have an object (like a DOM element) that you want to associate some data with, but you don't want to modify the object to add the data directly to it. So you use a Map with the object as key and your associated data as value.
typically, you'd want to use a WeakMap for this, so that if the original object goes away (GCd) the data is also released.
but a reason to use map instead of weakmap is that map is iterable and weakmap isn't.
so if you're willing to trade out that you need to do more manual work to manage the map entries (for cleaner GC), then you get the ability to enumerate all the entries of the map, which can be useful in certain cases.
QUESTION
I want to use javascript to send some images to my Server running PHP, which then saves these images. I have followed this guide, but my php script only recieves empty files.
I suspect that this piece of javascript from the guide:
...ANSWER
Answered 2020-Jan-12 at 16:52Without actually seeing all of the code, it's hard to pinpoint any specific issue. If I follow the guide you linked to, I'm able to see the image posted to my server. This is my source code:
process.php:
QUESTION
i using react hooks and got undefined in function 'deletePersonHandler' on 'setPersonsState'. on the tutorial using 'this.setstate' can delete each item,buat when i trying all data deleted and didn't return. when i see the log 'setPersonsState' 'undefined' solved with this
but still cant set that state,
...ANSWER
Answered 2020-Jan-09 at 06:30Replace this lane const persons = personsState.persons; By const persons = [...personsState.persons]; you need to include previous state like that setPersonsState({...personsState, persons}) or you delete the showPersons state which cause the if to be false
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install taniarascia.com
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page