There are many advantages of working from home. You can set your own hours, You do not need a particular costume, no travel costs included, ypu can be present when your child comes home from school, etc.
There are also some disadvantages of working at home: the distractions of friends and children, the support and collaboration can be more difficult. But we can not forget how important motivation is.
In your particular case, you have to decide whether the advantages outweigh the disadvantages.