Traditional Internet of Things (IoT) can achieve computing resource sharing (CRS) between edge devices and end devices. However, computing resources (CR) are not fully utilized, and the heterogeneity of CR cannot meet the demand for high-quality services; meanwhile, the distrust between computing nodes or with CRS platforms may hinder the implementation of CRS. In this paper, we propose a CRS framework based on blockchain and collaborative offloading of edge computing. In this framework, to achieve dynamic and efficient CRS among computing nodes, each computing resource requester (CRR) can freely contribute the CR obtained from the computing resource provider (CRP) for blockchain mining and AI services. We also propose a new honestly based distributed PoA via scalable work (HDPoA), in which the honesty of each computing node is considered. CR heterogeneity is formulated as a transaction probability problem. The CRS interactions between CRPs and CRRs are modeled as a multi-leader and multi-follower Stackelberg game, and an efficient method is developed to find the game's equilibrium point. Then, extensive simulations prove the correctness and effectiveness of the proposed framework and interaction model. Finally, we build a prototype of the CRS framework using Python and quantitatively measure and evaluate the performance of the proposed framework in terms of transaction latency.