There are many resources for exporting to Threejs but not many resources for exporting files from Threejs to be exported to 3d file editors. This is a simple exporter for Threejs that takes a SkinnedMesh as an argument and exports a rigged .dae model that can be loaded into Blender.
Still a very early version. Only supports SkinnedMesh, with a single material, a single texture, and must use Geometry and not BufferGeometry.
Example code using File Saver to download a blob from the browser to the client pc.
// Generate Mesh
var mesh = new THREE.SkinnedMesh(geometry, material);
var rootBone = armSkeleton.bones[0];
mesh.add(rootBone);
mesh.bind(armSkeleton);
// Export
var expt = new THREE.ColladaExporter();
var output = expt.parse(mesh);
var blob = new Blob([output], {
type: "model/vnd.collada+xml"
});
saveAs(blob, mesh.name + '.dae');
Example implementation where a file format is parsed in the browser using Threejs and exported to .dae format. Live Example. (Note that files from CDDATA/DAT* are required on the client side).