Here's a component that will generate the wireframe without the diagonal edges:
AFRAME.registerComponent("ngon-wireframe", {
schema: {
color: { type: 'color', default: 'black'}
},
init() {
const baseGeometry = this.el.getObject3D('mesh').geometry
if (!baseGeometry) {
console.warn("ngon-wireframe: no base geometry found")
};
const edges = new THREE.EdgesGeometry( baseGeometry );
const line = new THREE.LineSegments( edges, new THREE.LineBasicMaterial( { color: this.data.color } ) );
this.el.object3D.add( line );
this.el.getObject3D('mesh').visible = false;
}
})
Use it like this:
<a-box id="box"
position="0 0 -2"
ngon-wireframe="color:black">
</a-box>
Output looks like this:

Based on this THREE.js source: https://threejs.org/docs/#api/en/geometries/EdgesGeometry