FYI: if you use clipping masks in AI - the extents of the asset you export will be of all the artwork in that asset, which INCLUDES the boundaries of the CLIPPED art. In other words: the stuff you hid using the clipping mask is still used to determine the asset's size for export. FML, I know.
To fix it I just flatten the assets using this script:
This script assumes you have a single object being a clipping mask selected.
#target Illustrator
#targetengine main
// script.name = Unclip.jsx;
// script.parent = Herman van Boeijen, www.nimbling.com // 28-01-2019;
// Big thanks to CarlosCanto and MuppetMark on the Adobe Illustrator Scripting Forums
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
function Main(curDoc, sel, amountofselectedobjects, clipobject){
if (amountofselectedobjects){
if(curDoc.activeLayer.locked || !curDoc.activeLayer.visible){
alert("Please select objects on an unlocked and visible layer,\nthen run this script again.");
}else{
app.executeMenuCommand('ungroup');
app.executeMenuCommand('copy');
app.executeMenuCommand('Live Pathfinder Crop');
app.executeMenuCommand('expandStyle');
app.executeMenuCommand('ungroup');
app.executeMenuCommand('pasteBack');
app.executeMenuCommand('releaseMask');
sel = curDoc.selection;
amountofselectedobjects = sel.length;
app.executeMenuCommand('deselectall');
for (i = 1; i < amountofselectedobjects ; i++) {
killobject = sel[i];
killobject.remove();
}
}
}
}
//INIT, Is there a document open?
if ( app.documents.length > 0 ) {
var curDoc = app.activeDocument;
}else{
Window.alert("You must open at least one document.");
}
var sel = curDoc.selection; // get selection
var origsel = curDoc.selection;
var amountofselectedobjects = sel.length;
var clipobject = sel[amountofselectedobjects -1]; // BOTTOM OBJECT
var clipcolors = [];
Main(curDoc, sel, amountofselectedobjects, clipobject);
Standard disclaimer: if your computer ends up as a burning ball of flames, it's on you for not checking the script, not on me for trying to help.
If you use blurs or other pixel effects, also have a look at your rasterization settings, and the "margin" or something it adds around those effects.