# SeLight **Repository Path**: kmkfj/selight ## Basic Information - **Project Name**: SeLight - **Description**: 轻量化使用Selenium - **Primary Language**: Python - **License**: MulanPSL-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2023-06-20 - **Last Updated**: 2025-09-06 ## Categories & Tags **Categories**: Uncategorized **Tags**: Python, Selenium ## README # SeLight #### 介绍 轻量化使用Selenium。 引入selight文件,可以做一些初始化工作,使用时先把本地的chrome更新为最新版的浏览器,因为现在默认下载最新版的chrome driver。 文件中也定义了一些常用的动作,可以直接调用 使用方法 ```python import selight from selenium import webdriver import json from selenium import webdriver from selenium.webdriver.chrome.options import Options from selenium.webdriver.chrome.service import Service from selenium.webdriver.support.ui import WebDriverWait import time # import pyautogui from selenium.webdriver.support import expected_conditions as EC from selenium.webdriver.common.by import By from bs4 import BeautifulSoup # import requests from pathlib import Path if __name__ == '__main__': # 初始化 chrome_option = Options() chrome_option.set_capability("goog:loggingPrefs", {"performance": "ALL"}) chrome_option.add_argument("--start-maximized") # chrome_option.add_argument("--headless") # 无头模式,不打开浏览器窗口 service = Service("./chromedriver/chromedriver.exe") driver = webdriver.Chrome(service=service, options=chrome_option) driver.get("https://mp.weixin.qq.com/") time.sleep(10) ``` 软件架构说明 #### 安装教程 前提条件是安装好最新版的chrome 1. xxxx 2. xxxx 3. xxxx #### 使用说明 1. xxxx 2. xxxx 3. xxxx #### 参与贡献 1. Fork 本仓库 2. 新建 Feat_xxx 分支 3. 提交代码 4. 新建 Pull Request #### 特技 1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md 2. Gitee 官方博客 [blog.gitee.com](https://blog.gitee.com) 3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解 Gitee 上的优秀开源项目 4. [GVP](https://gitee.com/gvp) 全称是 Gitee 最有价值开源项目,是综合评定出的优秀开源项目 5. Gitee 官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help) 6. Gitee 封面人物是一档用来展示 Gitee 会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)