Dough.
I make oatmeal cookies with so many other things in them that the dough can barely hold them together. Chips, nuts, dry fruit, coconut; all that good stuff. I can imagine that strategy here.
You could do the same with your crispy onion. Make dough with butter, flour, egg and baking soda. Mix in the onions (gently! you don't want to smash them!). Or make cookie then gently press in onions to keep them whole. You want so much onion that it is barely a cookie.
You could deep fry these and then you would have a fritter. Or you could bake them into a cookie or bar.
If you add some sugar to the dough it will brown when you bake it. The thing will be converging more on a cookie if it is sweet but the browning is a good savory flavor.
You could add spices appropriate for what you are shooting for. An Indian style fried onion cookie could have curry type spices (cumin, black pepper, cardamom, coriander, ginger, slivered toasted almond etc) and it would be good and highlight the onion star of the show. I would add spice to dough and shake red pepper flakes on top.
In fact I have a bag of fried onions intended to top salads and Mac&cheese. I think I will try this cookie. Will followup.