Hello, I’ve recently updated from a legacy version of sketch (Sketch 93) to Sketch 2025.3.4, is there a way to Show/Hide all Slices globally anymore? I used to be able to hit (CTRL + E) which would toggle this on and off, but now I get a system alert sound every time I try to input that combo. The option also used to be in the VIEW > CANVAS section of the menu, but now that option is no longer there where the other “Show […]” options are located.
I can still individually go slice by slice and input (Shift + CMD + H) but that would take forever. Is there a solution this? Not sure why this was removed from the menu.
Hello @NaeBalm , thank you for your post and welcome to the forum!
We removed the ability to hide Slices, since some of our recent updates and enhancements have made Slices a bit redundant, so to speak. With the ability to Export Frames we made the decision to remove the option.
However, I’d like to hear your experience here. Could you tell us more about the situation where you’re missing this feature so we can understand the use case better? We had some related feedback back in the day, but most users were happy with the workarounds that we offered (involving the use of Frames and its Clip Contents property).
Hi JorgeF, thanks for the information,
It would be ideal to at least keep the toggle option for users converting from legacy forms of Sketch. I work for a gaming company where we have many bitmap graphics assets that are already slices. When opening up our legacy files, the numerous slice borders are a bit distracting to the overall view.
Additionally, having slices was a nice way of clearly seeing at-a-glance where the image bounds lay across multiple images and screens to determine consistency. Is there a quick way to view the bounds of ALL image based Frames? Would the Graphic option be a better alternative, and how would one go about converting all slices to this?
Moreover, does this redundancy mean the removal of slices altogether in the future ?
We’re in the same boat - all our elements have to be sliced for bitmap export. How exactly is your new “export frames/graphics” supposed to help with that workflow? Imagine having 800 of these components and the whole screen buzzing with slices! Before, we could hide them with a single click, and now we need workarounds.
And by the way, the method you suggested doesn’t just hide slices - it hides every element that has export enabled.
I have the same issue: I use frames as “pages,” creating one frame for each page of the website, for example. When I need to export parts of the design—either for client previews or for final production use—I use slices. However, the slice borders are annoying when continuing the design work, and it was very convenient to have a toggle to quickly show or hide them. I find it quite annoying to use the layer type filter and hide them manually. Is there a better workflow to do what I’m doing?
I’ve put together a simple script that hides or shows slices in the document — might be useful for someone. Just run it via Run Script, and if you like, you can save it as a plugin and assign a shortcut
var doc = context.document;
var pages = doc.pages();
var allSlices = [];
// Collect all Slice layers from the entire document
for (var p = 0; p < pages.count(); p++) {
var page = pages.objectAtIndex(p);
collectSlices(page.layers(), allSlices);
}
if (allSlices.length === 0) {
doc.showMessage("No slices found");
return;
}
// Check if there is at least one visible slice
var hasVisible = false;
for (var i = 0; i < allSlices.length; i++) {
if (allSlices[i].isVisible()) {
hasVisible = true;
break;
}
}
// If at least one slice is visible → hide all
if (hasVisible) {
for (var i = 0; i < allSlices.length; i++) {
allSlices[i].setIsVisible(false);
}
doc.showMessage("All slices hidden");
}
// If all slices are hidden → show all
else {
for (var i = 0; i < allSlices.length; i++) {
allSlices[i].setIsVisible(true);
}
doc.showMessage("All slices visible");
}
// --- Recursive slice collector ---
function collectSlices(layers, output) {
for (var i = 0; i < layers.count(); i++) {
var layer = layers.objectAtIndex(i);
// Check if the layer is a Slice
if (layer.className() == "MSSliceLayer") {
output.push(layer);
}
// Recursively check child layers (groups, symbols, etc.)
if (layer.layers) {
collectSlices(layer.layers(), output);
}
}
}
Thank you I tried this but, this isn’t a proper solution for what @igorreche had mentioned, “ the method you suggested doesn’t just hide slices - it hides every element that has export enabled.”
Some elements don’t have slices but have export enabled so it will hide them as well.