@openzeppelin/contracts/proxy/utils/Initializable.sol
vs
@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol
Why would anyone use proxies that do not support upgradable contracts? Instead, just create contract without a proxy, doesn't that save the trouble?
// SPDX-License-Identifier: MIT
pragma solidity 0.8.15;
import { Initializable } from "@openzeppelin/contracts/proxy/utils/Initializable.sol";
contract Test is Initializable {
address public owner;
constructor() public {
owner = msg.sender;
}
function initialize()
public
initializer
{
// logic
}
}
Aren't all proxies meant to support upgradable implementation contracts??
Another question is since it uses a non-upgradable contract, is it still susceptible to the constructor caveat? Openzeppelin Docs