Integration of |∇p|^2

I want to create a function that integrates the magnitude of the gradient of a polynomial with 2 variables squared. I created a generic polynomial using monomials and calculated |∇p|^2 and now i have a polynomial that consists of two variables and some of the terms have a combination of the two variables. I want to integrate w.r.t x first and then y. I know the general formula of integrating a polynomial but I’m integrating w.r.t one variable only then how can I work it out? I’m don’t want to use any package that will integrate it directly.

Perhaps Polynomials.jl has part of the solution?

I think you simply want to treat the other variable as a constant.

yes, this is what I want to do.