Although, Ananias and Sapphira (in my understanding) were not struck down for not sharing everything they had - they were struck down for their lie. They lied to the Holy Spirit.
Acts 5
3Then Peter said, "Ananias, how is it that Satan has so filled your heart that you have lied to the Holy Spirit and have kept for yourself some of the money you received for the land? 4Didn't it belong to you before it was sold? And after it was sold, wasn't the money at your disposal? What made you think of doing such a thing? You have not lied to men but to God."