I think the word importance has some different aspects for your question. Let's start with the general interaction between X-ray and matter. Here the importance of Compton and photoelectric scattering, i.e. their contribution to the total amount of absorption/scatter, is depend on the interaction material. For example Water and Calcium (bones) the Compton scattering will differ by 1.5 orders of magnitute mor medically used X-ray energies (~60-150kV) ( see fig. 1 in DOI:10.1055/s-0035-1569253).
Generally Compton scattering can be used for techniques as Compton-Imaging which is an active field of reseach and as far as I am aware of has yet not made it into at least medical imaging. I am not sure about material testing though.
As you talk about anti scatter grids, I assume that your question targets classical X-ray imaging. Here, Compton scattering in your object is generally a bad thing. It changes the angle of your x ray photon and it will hit some other pixel which is not on its initial trajectory. As a result you will loose the information of that particular x-ray quantum. This leads to a blurred background signal which will generally decrease your image quality. To get rid of these scattered photons, the typical aproach is to introduce an anti scatter grid, which is build out of small absorbing walls which are aligned to the focus of the X-ray tube. So ideally all photons which have been scattered will change their vector at some point and will subsequently be blocked by the anti scatter grid.
Looking at the whole imaging chain however, compton scattering is very important and wanted in Xray sensor as it is a way to absorb the X-ray energy in order to detect it.